My Requirement:
I have around 100 tests in my test suite.
I don't want to hardcode the group name in the tests source code.
I want to choose the tests that I want to run each time but want to pass that list from an external source (csv/json/xml, etc) to the TestNG program via a maven command.
I can parameterize in the source code if needed, something like below:
@Test(groups = {"param1toBeReadFromExternalFile"})
@BeforeClass(groups = {"param1toBeReadFromExternalFile"})
Is this something that is achievable in TestNG?
Reason for this requirement:
The requirement is for external teams (that don't have access to source code) to be able to tag selective tests from the 100 tests with a specific group name and run tests on the fly without the need to check-out and check-in code.