Open vikramvi opened 8 years ago
Hi,
Can we please mention a section about passing command line custom arguments and accessing same from code ?
e.g. user id and password
mvn clean verify -Dtest.email="test@yahoo.com" -Dtest.password="$pass$"
System.out.println(System.getProperty("test.email")); System.out.println(System.getProperty("test.password"));
Thanks & Regards, Vikram
see https://serenity-bdd.github.io/theserenitybook/latest/environment-specific-config.html you can access environment variables with the environment variables class
Hi,
Can we please mention a section about passing command line custom arguments and accessing same from code ?
e.g. user id and password
mvn clean verify -Dtest.email="test@yahoo.com" -Dtest.password="$pass$"
System.out.println(System.getProperty("test.email")); System.out.println(System.getProperty("test.password"));
Thanks & Regards, Vikram