Run only the smoke tests with Maven
QuizEasy-MediumJava only
Tests are marked @Test(groups = "smoke") in TestNG (or @Tag("smoke") in JUnit 5), which puts a label on each test. Which command runs only the tests with that label?
- mvn test -Dgroups=smoke
- mvn test -Dtest=smoke
- mvn smoke
- mvn test -Psmoke
This question is part of Pro+
Pro+ opens every question in Interview Prep and the mock interview. Every article and the first 2 questions of each topic stay free. Hands-on Selenium and API tasks follow their course lesson's own lock.