The problem with racism and sexism is that the victim confuses opposition to them as being a byproduct of their minority status rather than their position/character.
Not all. Racism and sexism can be very easily recognized by those who don't live in denial.
For example, opposing or politically attacking a minority woman candidate over her support of Medicare for All or the Green New Deal is not sexist or racist. Opposing or politically attacking a minority male political leader over his support of the Iran nuclear deal or his health care plan is not sexist or racist either.
However, attacking or opposing a woman candidate by claiming she slept her way to the top is sexist. Attacking or opposing a minority woman candidate by calling her and other women candidates "mean" or "nasty" can have sexist/racist overtones. Attacking or opposing a minority male leader by calling him names based on his skin color, or by claiming he isn't really an American, or trying to paint him as "different" is all racist is nature.
Opposition based in policy differences and opposition based in racism and sexism are very easily distinguishable.