When can I test?

How early can you test after having sex to possibly get a positive test?