Confused

My husband and I have been trying for over a year with no luck, the other day I took a random pregnancy test and it came out positive, then I took 2 more and they came out negative why would that happen :(