3

I have a Hudson CI system set up and for the moment it is used for building a project and running some unit tests. My next step is to integrate the memory leak detector Purify into the build cycle. Now I want to start the unit tests also inside purify and for this I have created a new batch task which runs following command:

purify.exe /SaveTextData MyExecutable.exe --test TestLibrary.dll --output xml

As I read in the Purify documentation the /SaveTextData option is used in order to run purify not in GUI mode. If I run this command on my local workstation in the command line it works perfectly. But in case it is started by Hudson, nothing happens. Unfortunetly there are no logs of purify...

Has someone ever tried to start purify either by Hudson or any other CI system?

Thanks in advance.

Best regards

Martin

EDIT: I forgot to tell you, that I have Hudson running as master and slave on different computers. On the master I have configured a task which should start the unit tests within purify on the slave. I am running the slave via JNLP.

EDIT 18.03.2010:

Ok, so finally I am a bit closer the source of the problem.

I have discovered, that running my unit tests in purify locally the log file EngineCmdLine.log contains three commands.

I am starting purify with following command:

purify.exe /SaveTextData TestRunnerConsoleWD.exe --test TestDemoWD.dll

Output of EngineCmdLine.log when starting purify manually:

File: D:\workspace\hudson\workspace\Purify_TestFW_CommonsCoreTest_Cpp_msvs9\TestRunnerConsoleWD.exe

File: C:\WINDOWS\system32\ws2_32.dll

File: D:\workspace\hudson\workspace\Purify_TestFW_CommonsCoreTest_Cpp_msvs9\TestDemoWD.dll

Output when starting via Hudson:

File: D:\workspace\hudson\workspace\Purify_TestFW_CommonsCoreTest_Cpp_msvs9\TestRunnerConsoleWD.exe
File: C:\WINDOWS\system32\ws2_32.dll

File: D:\workspace\hudson\workspace\Purify_TestFW_CommonsCoreTest_Cpp_msvs9\TestDemoWD.dll

File: D:\workspace\hudson\workspace\Purify_TestFW_CommonsCoreTest_Cpp_msvs9\TestDemoWD.dll

The error output of purify:

Instrumenting: 
  BtcTestDemoWD.dll 313856 bytes

Purify: While processing file > D:\workspace\hudson\workspace\Purify_TestFW_CommonsCoreTest_Cpp_msvs9\TESTFWWD.DLL:
Error: Cannot replace file c:\Programme\IBM\RationalPurifyPlus\PurifyPlus\cache\BTCTESTFWWD$Purify_D_workspace_hudson_workspace_Purify__TestFW__CommonsCoreTest__Cpp__msvs9.DLL.    

Is it in use?

TESTFWWD.DLL 505344 bytes


Unable to instrument D:\workspace\hudson\workspace\Purify_TestFW_CommonsCoreTest_Cpp_msvs9\TestDemoWD.dll (0x1)

Question is, why is purify starting twice a command with the TestDemoWD.dll library?

Alejandro Galera
  • 3,445
  • 3
  • 24
  • 42
Martin
  • 968
  • 3
  • 10
  • 19
  • Are you running Hudson as a windows service? Some programs aren't capable of running under the service account setup. – TheDon Mar 04 '10 at 12:56
  • Hudson master is running from command line. The slave (I have added this info right now in my question) is running on a different computer and started via JNLP. I guess when I am starting the slave via JNLP from account A, the applications started by the slave will run under account A, am I right? – Martin Mar 05 '10 at 08:50
  • log into the slave with account A and run the purify manually. You should find out more this way. – Peter Schuetze Mar 05 '10 at 18:46
  • Well, I already have done this. When running purify manually everything is ok. It's starting the tests and creating some reports at the end. – Martin Mar 08 '10 at 13:35
  • I don't get it. I have started now the slave as a windows service. The windows service is using also my account A but nothing works. I have no idea what the problem is... – Martin Mar 08 '10 at 14:58

0 Answers0