The presence of GBS can be detected using a swab of your lower vaginal and anal area. After taking a sample, your health care provider will send it to a lab for testing.