Closed shine17 closed 9 years ago
Hi, this is a known issue, but noone has wanted to fix it. I've never used MsTest in my life and every time I have it's been to replace it with NUnit. ;)
https://github.com/Albacore/albacore/issues/125 was where we discussed it...
Thanks. I change it to Nunit and it worked
will this ever get fixed?
@andyfenna Only ever through pull requests. Feel free to fix it.
I've fixed it, needs testing etc, i'll do a pull request now ;)
Below is the test_runner code -
test_runner :tests do |tests| tests.files = FileList['C:\GitRepos\shinetest\testapps\Albacorerakesample\AlbacoreRakeDotnetBuildSample\AlbacoreRakeDotnetBuildSample.Tests\bin\Release\AlbacoreRakeDotnetBuildSample.Tests.dll'] tests.exe = 'C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\MSTest.exe' tests.native_exe end
The error am getting is Invalid switch "albacorerakedotnetbuildsample.tests.dll". Below is the trace -
Invalid switch "albacorerakedotnetbuildsample.tests.dll". For switch syntax, type "MSTest /help" C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/cross_platform_cmd.rb:263:in'
Tasks: TOP => tests
raise_failur e' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/cross_platform_cmd.rb:242:in
block in han dler_with_message' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/cross_platform_cmd.rb:111:incall' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/cross_platform_cmd.rb:111:in
block in sys tem' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/cross_platform_cmd.rb:247:inhandle_not_f ound' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/cross_platform_cmd.rb:87:in
system' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/task_types/test_runner.rb:73:inexecute' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/task_types/test_runner.rb:104:in
block in execute_tests_for' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/task_types/test_runner.rb:138:inhandle_d irectory' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/task_types/test_runner.rb:98:in
execute_t ests_for' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/task_types/test_runner.rb:92:inblock in execute' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/file_list.rb:81:in
each' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/file_list.rb:81:ineach' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/task_types/test_runner.rb:90:in
execute' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/albacore-2.5.1/lib/albacore/dsl.rb:82:inblock in test_runner' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/task.rb:240:in
call' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/task.rb:240:inblock in execute' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/task.rb:235:in
each' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/task.rb:235:inexecute' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/task.rb:179:in
block in invoke_with_call_chain' C:/opscode/chef/embedded/lib/ruby/1.9.1/monitor.rb:211:inmon_synchronize' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/task.rb:172:in
invoke_with_call_chain' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/task.rb:165:ininvoke' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/application.rb:150:in
invoke_task' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/application.rb:106:inblock (2 levels) in top_le vel' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/application.rb:106:in
each' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/application.rb:106:inblock in top_level' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/application.rb:115:in
run_with_threads' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/application.rb:100:intop_level' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/application.rb:78:in
block in run' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/application.rb:176:instandard_exception_handlin g' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/lib/rake/application.rb:75:in
run' C:/opscode/chef/embedded/lib/ruby/gems/1.9.1/gems/rake-10.4.2/bin/rake:33:in<top (required)>' C:/opscode/chef/embedded/bin/rake:23:in
load' C:/opscode/chef/embedded/bin/rake:23:in `