|Can't connect to AUT using Jenkins...occasionally [message #1076640]
||Wed, 31 July 2013 13:25
| Youssef Bagoulla
Registered: July 2013
I'll do the short version first, then the long one after as I'm sure my setup is less than optimal:|
Short story - Using jubula_7.1.00054, I've automated it to run a Jubula Job in Jenkins which contains multiple testsuites. All testsuites reference the same AUT which is started prior to running testexec. Occationally, not always, but occationally it will complete the first testsuite but then claim "!!Error occurred !! Could not connect to AUT" Running the Jenkins job again it makes it through all 5 test suites. Maybe 1 out of 10 times it fails to connect. What's going on here? Anyway to print more debug info? I have no idea how to repeat the issue.
Long story - My setup feels really hacky so please recommend another solution if there is a more accepted practice.
Goal: Create multiple Jubula Jobs which contain multiple test suites which map to mulple Jenkins Jobs to tests my RCP Application. The AUT is the same for all jobs however the workspace used by each is unique per Jenkins/Jubula Job. Developers need only to drag and drop their Test Suite into a Jubula Job and hit Run on the Jenkins job to test out their test suite in a clean, known environment. In theory, these jobs can run in parallel on different VNCSERVERs which run unique AUT Agents on different ports.
1.) Each Jenkins Job starts by pointing to:
a.) Jubula XML configuration file which defines: Project, Version, autconfig, dbscheme, dbuser, dbpw, server, port, language, & testjob.
b.) RCP Workspace
c.) VNC Display
d.) AUT Agent Port
e.) AUT_ID (Looks like I define this in the xml file as well, not sure if that's the problem...)
2.) Setup VNC Server on given display
3.) Start AUTAGENT on given port (bg the process)
Can't continue until the AUTAGENT is up and running, but autagent runs in fg unless backgrounded! How do you know when it's up?
4.) While port not open, sleep 1 sec. (Hacky solution #1)
Need to launch my AUT with a given workspace, autrun cannot be passed the -data flag to set AUT workspace! How can I set the workspace?
5.) On the fly, create temporary executable script which will launch my AUT with -data flag. (Hacky solution #2)
Can't launch testexec unless I know my application is loaded & jubula jar file has started! How can I tell via my bash script when the jubula jar has loaded?
6.) Sleep 30 seconds.....should be plenty of time (Hacky solution #3)
7.) Launch testexec pointing it to the XML configuration & result dir, and jubula workspace. This SHOULD run through all testsuites and the AUT should stay up and running the whole time. 90% of the time it works just fine. Occationally it only makes it through the first testsuite and then it claims it can't connect to AUT...the but AUT hasn't changed and is still running!
8.) Stop AUT Agent for particular port
9.) remove temporary script.
10.) Kill VNC Server
Powered by FUDForum
. Page generated in 0.02326 seconds