Sex before due to take a pregnancy test

I think I may already be pregnant and will start testing tomorrow 9DPO.

Can I have sex tonight? Will it affect the results in the morning??