Confusing tests

Anybody know the reason when you test negative on a pregnancy test but are actually pregnant? I know it doesn't happen very often but 😂

I felt super crampy around the time my period was due, then it was three days late and lasted half a day. I was feeling exactly the same as my previous pregnancies so I tested and got four vfls on different brands. Then a few completely negatives. Since then I've been having nausea on and off aversion to certain foods and started to put on weight. Completely missed my next period got three negative tests and one blazing positive (which I presume was faulty)...