I have a few testcases that are written using Selenium and JUnit. I would like to write a windows script to start the programs. I referred to the solution @ Simple Script to Run Java Applications on Linux and Windows. The solutions @ how to run junit test cases from the command line provide a method to run the Junit test cases using:
java -cp /path/to/directory/java/junit.jar org.junit.runner.JUnitCore [test class name]
I am however interested in creating a generic script for windows which would run the harness. I have little or no knowledge about the windows powershell, I would love to hear about a solution that could make use of powershell scripts to do the same.
Having said that, it would be great if you could guide me to do the same for Linux.
To summarize:
- Windows script to run JUnit 4.x and Selenium programns
- Approach to do the same in windows powershell
- Similar script for Linux