How long should i wait

t
How long should i wait to take a test? 
Me and my SO have unprotected sex and nothing wrong has happened and we were extremely careful yesterday (he didn't use the bathroom before we had sex) but he doesn't remember if he used the bathroom after he masturbated that morning... My period is supposed to come in the next 4-5 days so idk if i can even get pregnant with it being so close to my period date🙄