Reputation: 3256
I have a C# .NET unit test project that uses ChromeDriver to run automated UI tests on a web page. This is on Windows 7 64 bit. The tests run fine from within Visual Studio 2010.
I have set up a Jenkins box to run the tests locally (on master), which is a Windows 2008 Server. The tests build, but my MSTest command fails mysteriously:
"c:\program files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\MSTest.exe" /resultsfile:c:\jenkins\jobs\FXO_UI_Tests\workspace\TestResults.TRX /testcontainer:c:\jenkins\jobs\FXO_UI_Tests\workspace\bin\Debug\Calculators.FXOptions2.Automation2.dll /testsettings:c:\jenkins\jobs\FXO_UI_Tests\workspace\FXO.testsettings
With this output:
Microsoft (R) Test Execution Command Line Tool Version 10.0.30319.1
Copyright (c) Microsoft Corporation. All rights reserved.
Loading c:\jenkins\jobs\FXO_UI_Tests\workspace\FXO.testsettings...
Loading c:\jenkins\jobs\FXO_UI_Tests\workspace\bin\Debug\Calculators.FXOptions2.Automation2.dll...
c:\jenkins\jobs\FXO_UI_Tests\workspace\bin\Debug\Calculators.FXOptions2.Automation2.dll
The file exists.
c:\jenkins\jobs\FXO_UI_Tests\workspace>exit 1
Build step 'Execute Windows batch command' marked build as failure
The irritating part is that the same MSTest command, pasted in a command window, runs perfectly fine. I dont see "The file exists" when I run manually.
I have tried running Jenkins as a service, but it currently is running standalone in a logged-in user account. The same Jenkins set up can open Chrome.exe so I can't understand why the command just ends.
Please help!
Upvotes: 0
Views: 1173
Reputation: 3256
Found it! "The file exists." was the key. Turns out that the TEMP folder that the Jenkins uses is somehow different than the logged in user (despite being the same user). And that folder was absolutely full of every file name possible. Clearing out the temp folder fixed it.
Upvotes: 1