question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Test targets need to be part of main SDK

See original GitHub issue

Right now, it seems the only way to invoke unit test projects via the test platform is to use dotnet test on the project file. The problem is that forces the CoreCLR version of the Build tasks and not all tasks work on CoreCLR.

For example: https://github.com/Reactive-Extensions/Rx.NET/blob/f339ba7c0821d00f9c0cb29186c97713765a6d03/Rx.NET/Source/Tests.System.Reactive/Tests.System.Reactive.csproj

I cannot simply run dotnet test on that because the GitVersionTask is .NET Desktop only. That’s fine for building, but I then need a way to invoke the test platform once per target framework with the right parameters.

It should do whatever dotnet test is…I think it’s going to vstest.console /Framework: … with the supported frameworks.

It seems that Microsoft.TestPlatform.targets is in the CLI build but not in the main SDK. It should be in the main SDK for use with msbuild.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
clairernovotnycommented, Jan 9, 2017

This really needs to be in 1.0…otherwise, given that these targets are distributed with VS 2017 and not via NuGet, it’ll need to wait for Update 1, wont’ it?. We need a coherent unit test strategy out-of-the-box.

0reactions
srivatsncommented, Jan 27, 2017

This issue was moved to Microsoft/vstest#387

Read more comments on GitHub >

github_iconTop Results From Across the Web

Code signing is required for product type Unit Test Bundle ...
My app target is code signing just fine - but my test target is not. I bought a new computer, created a new...
Read more >
Configuring a new target in your project
To view the targets in a project, select the project in the navigator area. The editor area displays the current project and target...
Read more >
NETSDK1045: The current .NET SDK does not support ...
NET SDK version. Open the project file (.csproj, .vbproj, or .fsproj) and check the target framework. This is the version of the ...
Read more >
Meet Google Play's target API level requirement
When you upload an APK, it must meet Google Play's target API level requirements. Starting on August 31, 2023: New apps must target...
Read more >
Advanced test setup | Android Studio
Perform more advanced testing as part of your Continuous Integration setup. This page describes various ways to configure your tests when the ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found