pregnancy test - best time to take it?

Breanna • 28 years old, lost my first baby 💔 12/11/17 - 1/31/18 👼 Married💍 Mama 👩‍👧
So I'm still at the in between stage of getting of the depo to go on the pill. I could technically be off the depo but I don't know until my period comes back. Last night my boyfriend and I had unprotected sex and didn't pull out (my fault), so should I wait a couple weeks to take one? If I'm pregnant it won't be a bad thing, I'm almost 22 so if we accidentally got pregnant it would be okay. Thanks!