Want to change value of a serenity property at run time.
Reading the property as below:
SerenityVar serenityVar = SerenityVar.getInstance();
EnvironmentVariables variables = serenityVar.getSerenityProps();
variables.getProperty("webdriver.base.url");However, at run-time, want to change the value of "webdriver.base.url"
Tried using
variables.setProperty("webdriver.base.url", "neWValue");but did not work
--
You received this message because you are subscribed to the Google Groups "Serenity BDD Users Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to thucydides-users+unsubscribe@googlegroups.com.
To post to this group, send email to thucydides-users@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Environment variable are immutable, since changing them could have very adverse effects on multi-threaded testing, and you can't know where the values have already been used. Why do you want to change the base url at runtime?
On 5 September 2017 at 04:24, Kamini Karakoti <k.kar...@gmail.com> wrote:
Want to change value of a serenity property at run time.Reading the property as below:SerenityVar serenityVar = SerenityVar.getInstance();
EnvironmentVariables variables = serenityVar.getSerenityProps();variables.getProperty("webdriver.base.url");However, at run-time, want to change the value of "webdriver.base.url"Tried usingvariables.setProperty("webdriver.base.url", "neWValue");but did not work
--
You received this message because you are subscribed to the Google Groups "Serenity BDD Users Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to thucydides-use...@googlegroups.com.
To post to this group, send email to thucydid...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
"-Dserenity.driver.capabilities='webdriver.base.url:newValue;shouldUseSingletonTestManager:true'"
Visit this group at https://groups.google.com/group/thucydides-users.