i have irregular periods. is a pregnancy test accurate 18 days after sex?

please tell me!