Jenkins has its own environment setup - so you will need to add any custom pythonpath tweaks to the global environment on the Manage Jenkins -> Global Configuration page, or add it to a relevant slave node if only that node runs it.
On 17 February 2012 19:02, SteveB <doc...@gmail.com> wrote: > Trying to use Jenkins to run python-selenium-testng scripts to do > website functional testing and have Jenkins collect the testng > result. (FYI this is on a ubuntu system) > > Having problem getting Jenkins to run the python scripts with either > the build shell or the shiningPanda python plugin. The errors from > the console are one or two depending on how I configure the tests. > > 1, the python source can't be found. That appears to semi-solved > using the Custom Workplace directory. > > 2. The biggest issue is when Jenkins does find the source and run the > script I get errors that the selenium library can't be found by > python. > > From testing the python script can be run from the command line by any > account except the Jenkins created account. Something about the > shell Jenkins spawns to run tests in doesn't include the python lib's > everyone else can find. I even su'd into the jenkins account and it > won't run the script like all the other accounts can. ShiningPanda > python plugin has an option to use global lib's and checking that does > not help. > > So could questions..... > 1. Can Jenkins be used like this to run python scripts that launch > firefox and testng return results. > > 2. Assuming answer to question one is yes, What do I need to do to > get the jenkins account to find and use the same lib's the rest of the > system can? > > Thanks for any pointer or advise. -- Danny Staple Director, ODM Solutions Ltd w: http://www.odmsolutions.co.uk Blog: http://orionrobots.co.uk/blog1-Danny-Staple