Is there any way that we can provide command line argument in JUnit or TestNG tests?
Asked
Active
Viewed 703 times
0
-
3You could look at this post http://stackoverflow.com/questions/2884163/pass-command-line-arguments-to-junit-test-case-being-run-programmatically – HJK Apr 29 '15 at 11:49
-
Do you want to pass parameters to the JVM (e.g. -Dsome.property=foobar) or in the way they would be passed to the `main` method (e.g. java YourApp someArgument)? – SubOptimal Apr 29 '15 at 11:55
-
Sorry for the late reply.i want to pass some argument in vm argument in eclipse and retrieve from my test class. – neerajhatwal May 07 '15 at 05:42