properties-example
env properties is detected in following manner
- passed from command line as -Denv
- from testng xml
- default value from the test file
For e.g.
- if -Denv=prod and testng.xml=qa and default value in test is dev. Then prod.properties will be loaded
- if -Denv is not passed then qa from testng xml will used and qa.properties will be loaded
- if both testng.xml and -Denv are not passed then dev.properties will be loaded
Reference - http://www.testautomationguru.com/selenium-webdriver-how-to-execute-tests-in-multiple-environments/