I am using eclipse with maven for a mobile automation test on a mobile webpage.
I am defining the following in my pom.xml
<properties>
<MY_VARIABLE>www.google.com/</MY_VARIABLE>
</properties>
but when i am calling this using
String testurl1 = System.getProperty("MY_VARIABLE");
it always seems to return null.
I also tried the following way of defining variable
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.16</version>
<configuration>
<systemPropertyVariables>
<MY_VARIABLE>www.google.com</MY_VARIABLE>
</systemPropertyVariables>
</configuration>
</plugin>
but still am getting the value as null.
I could use some help Thanks.