First we need a directory in the webapps folder of jetty where the tests are placed. In this folder the following directories are placed in. The test directory, the siesta sources, the test-harness.js and the test-harness.html. This has to commit to subversion to give jenkins the chance of knowing the sources. A setup from test-harness.js and the test-harness.html you can find here: https://www.bryntum.com/docs/siesta/#!/g ... ng_started
After your environment is setted up we have to batch the process for jenkins. The jenkins workflow looks like the following:
- Set up the project by copying the source files of the application under tests in your test folder of the webapps directory from the jetty server
- Run the jetty servers start.jar on jenkins with setting up a stop port and a stop key
- call phantomjs on localhost in jenkins with a JUnit report format
- after phantomjs passes all test with success or fail call the start.jar of jetty with the stop command using the stop key and stop port
- remove the project sources which were copied to the jettys webapps directory in jenkins for cleaning up the project again on jenkins and because of you do not want to have this in your subversion when you run this batch file on your local machine
My batch file Run_Siesta_Tests.bat looks like this:
I hope this post is helpful for all siesta developers.
Thank you for all the help I got in this forum.