Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[test_runner] Parameterize test_runner working directory change #111

Open
mobill opened this issue Apr 7, 2014 · 1 comment
Open

[test_runner] Parameterize test_runner working directory change #111

mobill opened this issue Apr 7, 2014 · 1 comment

Comments

@mobill
Copy link

mobill commented Apr 7, 2014

Please parameterize the working directory change in test_runner.

In rc12, test_runner changes the working directory to the directory specified for the test assembly. I do not want the working directory to change.

assemblies:

"../source/App1/Tests/Unit/App1.Tests/bin/release/App1.Tests.dll",
"../source/App2/Tests/Unit/App2.Tests/bin/release/App2.Tests.dll"

rakefile working dir:

c:\build-dir\job\deploy

resulting command line in rc12:

..........\deploy\Tools\NUnit.2.5.10.11092\nunit-console.exe App1.Tests.dll /xml=../Build/Output/unit_test_results.xml

should be:

Tools\NUnit.2.5.10.11092\nunit-console.exe ../source/App1/Tests/Unit/App1.Tests/bin/release/App1.Tests.dll /xml=../Build/Output/unit_test_results.xml

See issues 109 and 110

I understand your point about the test data location, but you're assuming that test data will be local to the test assembly. Forcing the working directory just isn't a good solution. It is hidden, unexpected behavior. It should be parameterized and under my control.

NOTE the results xml file specified in the command parameter will now end up in a completely unknown location, assuming it's created at all.

@haf haf added this to the v2.0 Release milestone Aug 1, 2014
@haf haf added the help wanted label Aug 1, 2014
@haf
Copy link
Member

haf commented Aug 21, 2014

Ok, I've gone through this a bit more methodologically and this is the intended behaviour. There's always a fallback on simply calling the executable directly, like so:

system 'src/packages/NUnit.Tools.2.6.3/tools/nunit-console.exe',
       'src/lib.dll',
        clr_command: true

I'm remaking this a feature request. I'm open to pull requests if you want a flag that modifies the default behaviour.

@haf haf added api_change and removed major_bug labels Aug 21, 2014
@haf haf modified the milestones: v2.0 Release, v2.1 Release Aug 21, 2014
@haf haf changed the title Parameterize test_runner working directory change [test_runner] Parameterize test_runner working directory change Dec 2, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants