How to setup a Jenkins slave to run Squish tests

Last edited on

The following steps describe how to setup a Jenkins slave to run a Squish test:

StepDescriptionExample
1First of all Squish needs to be installed on the slave machine as described at How to Install Squish.Squish installed at C:\Squish
2Setup a node inside Jenkins at Manage Jenkins | Manage Nodes | New Node. For Windows slaves please make sure to not start the slave as Windows Service at Launch method. Windows Services are intended to run command line applications but not to run applications which consist of a GUI. Starting the Jenkins slave as JNLP via Launch slave agents via Java Web Start works fine.Node name is windows_qt47
3Read the article Automation on Windows without a screen to make sure you don’t run into the pitfalls listed there.
4To configure where the Squish Jenkins Plugin can find a Squish installation open Manage Jenkins | Configure System | Squish | Advanced configuration. Each line of the text area consists of a simple key value mapping. To configure a Squish installation located at C:\Squish choose an arbitrary name / key like squishOnWindowsForQt47 and append the /squishPath tag to assign the absolute path. For convenience you can use the node name too of course.slaveWinQt47/squishPath=C:\Squish

…or…

windows_qt47/squishPath=C:\Squish
5Finally use the Config option inside the Squish build step to enter the name / key used inside the advanced configuration. This way the Squish Jenkins Plugin knows where to find the Squish installation on the slave.windows_qt47

While executing the Jenkins job the squishrunner as well as the squishserver will be executed on the Jenkins slave. The test suite configured inside the Test Suite option of the Squish build step refers to the Jenkins slave file system not to the Jenkins master node file system.

The Squish Jenkins Plugin supports using the Jenkins environment variables listed at Jenkins Set Environment Variables. A common approach is to checkout the test suite from a version control system into the job’s workspace directory and to use the WORKSPACE Jenkins environment variable e.g. ${WORKSPACE}/suite_book.