We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
This new issue is related to #456, requested by @MarcoRossignoli
The difference is, this issue is to see if a fall-back in the code below would address the issue and allow us to use Coverlet using .net core 2.1.400.
Exception:
Data collector 'XPlat code coverage' message: System.MissingMethodException: Method not found: '!!0 Microsoft.VisualStudio.TestPlatform.ObjectModel.DataCollection.SessionStartEventArgs.GetProperty Value(System.String)'. at Coverlet.Collector.DataCollection.CoverletCoverageCollector.GetTestModules(SessionStartEventArgs sessionStartEventArgs) at Coverlet.Collector.DataCollection.CoverletCoverageCollector.OnSessionStart(Object sender, SessionStartEventArgs sessionStartEventArgs).
Fallback:
private static IEnumerable<string> GetPropertyValueWrapper(SessionStartEventArgs sessionStartEventArgs) { try { return sessionStartEventArgs.GetPropertyValue<IEnumerable<string>>(CoverletConstants.TestSourcesPropertyName); } catch (MissingMethodException) { using (var enumProperties = sessionStartEventArgs.GetProperties()) { while (enumProperties.MoveNext()) { if (enumProperties.Current.Key == CoverletConstants.TestSourcesPropertyName && enumProperties.Current.Value is IEnumerable<string> propertyValue) { return propertyValue; } } } throw; } }
The text was updated successfully, but these errors were encountered:
From what I can tell, looks like test sources was added only in 2.1.7 in dotnet/cli#11312
Sorry, something went wrong.
@vagisha-nidhi does it make sense?
cc: @nohwnd
Possible related PR microsoft/vstest#1962 Spec https://github.com/Microsoft/vstest-docs/blob/master/RFCs/0026-Passing-TestPlatform-Properties-to-DataCollector.md Cannot find in release changelog https://github.com/Microsoft/vstest-docs/blob/master/docs/releases.md
Closed for stale conversation.
No branches or pull requests
This new issue is related to #456, requested by @MarcoRossignoli
The difference is, this issue is to see if a fall-back in the code below would address the issue and allow us to use Coverlet using .net core 2.1.400.
Exception:
Fallback:
The text was updated successfully, but these errors were encountered: