Varies by state
Most states require you to name a father for the birth certificate.
Then, in the majority of states, you can request testing through your local health department. This is done now by a swab on the child's cheek and one from potential fathers. This does require the dad to allow himself to be tested. Some states mandate potential dads to submit to test or be the responsible party.