COVID-19 tests can detect either SARS-CoV-2 or biomarkers of SARS-CoV-2, the virus that causes COVID-19, or antibodies that your body makes after getting COVID-19 or after getting vaccinated.
Tests for SARS-CoV-2 tell you if you have an infection at the time of the test.