Implantation bleeding? (Edited)

Tonight i got a little crampy and when i wiped i was spotting a brown rust color ive never experienced before.

My question is, If this is potentially implantation bleeding, how long after it ends can i take a pregnancy test?

Thank you 🙏

Edit: my period is very irregular so i never truly know when it is coming. This app tells me its due in 8 days and another app tells me its due in 16 days. However my last period was may 13-16

I had unprotected sex in may after my period and again just over a week ago where he came in me twice.