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
fix: IsOsPlatform() fails on older .NET Framework Versions #1552
Conversation
… NETSTANDARD2_0` blocks
Codecov Report
@@ Coverage Diff @@
## main #1552 +/- ##
=======================================
Coverage 73.03% 73.03%
=======================================
Files 408 408
Lines 25575 25576 +1
=======================================
+ Hits 18678 18679 +1
Misses 6897 6897
|
src/Agent/NewRelic/Agent/Core/NewRelic.Agent.Core/Environment.cs
Outdated
Show resolved
Hide resolved
I think |
@chynesNR It does need that protection, but I opted not to add it, as doing so broke the unit tests for that class (we only have .NET 462 unit tests for Core). I'll add a comment to the class that will hopefully dissuade folks from using it outside of the protection of .NET Standard 2.0+. |
…pServices.RuntimeInformation method calls
Thank you for submitting a pull request. Please review our contributing guidelines and code of conduct.
Description
Moved all calls to
RuntimeInformation.IsOsPlatform()
within a#if NETSTANDARD2_0
block.Author Checklist
Reviewer Checklist