STI Testing?

How long after sex should you wait to be tested for STDs