testing

how long do i have to wait to do a pregnancy test after having sex?