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.

Missing method with vstest integration

See original GitHub issue

Hi,

I’m trying to use the VSTest integration and getting the following:

Data collector 'XPlat code coverage' message: System.MissingMethodException: Method not found: '!!0 Microsoft.VisualStudio.TestPlatform.ObjectModel.DataCollection.SessionStartEventArgs.GetPropertyValue(System.String)'.
   at Coverlet.Collector.DataCollection.CoverletCoverageCollector.GetTestModules(SessionStartEventArgs sessionStartEventArgs)
   at Coverlet.Collector.DataCollection.CoverletCoverageCollector.OnSessionStart(Object sender, SessionStartEventArgs sessionStartEventArgs).

I’m using the .NET Core 3 SDK Preview 6 3.0.100-preview6-012262.

The test project has the following:

<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.1.1" />
<PackageReference Include="coverlet.collector" Version="1.0.0" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.1" />
<PackageReference Include="FluentAssertions" Version="5.6.0" />
<PackageReference Include="xunit" Version="2.4.1" />

I also tried with Microsoft.NET.Test.SDK 16.2.0-preview-20190606-02, which was just published 5 hours ago.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:2
  • Comments:13 (4 by maintainers)

github_iconTop GitHub Comments

5reactions
clairernovotnycommented, Jun 24, 2019

Update for anyone following along – the 16.1.1 vstest runner has been merged into the latest .NET Core 3 Preview 7 nightlies, so this works now.

1reaction
MarcoRossignolicommented, Jun 9, 2019

@onovotny I close issue because the question has been anwered by @vagisha-nidhi The 2.2.300 changes haven't flown into 3.x Preview 6.

Read more comments on GitHub >

github_iconTop Results From Across the Web

System.MissingMethodException Unit Test - net core
I encountered this issue while testing a class from a project that had a dependency on a Nuget package that had been updated...
Read more >
Can't run vstest - Microsoft Q&A
The strange thing is that I can run the tests in the VS 2022 Test Explorer. Any ideas what I am missing? Visual...
Read more >
Integration Tests for ASP.NET Core Web APIs using MSTest
These integration tests are helpful in catching cases of missing ... snippet shows an example integration test for an action method in a...
Read more >
Most Complete MSTest Framework Tutorial Using .Net Core
Learn about the MSTest Framework using .Net Core in Selenium C# and the aspects related to cross browser testing and parallel testing in ......
Read more >
Test Explorer not discoverying test methods
I created one test method in a test project in a solution, did a build, test explorer not seeing test. Close solution, open...
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