Make CoreFx.Private.TestUtilites RID-agnostic#36207
Make CoreFx.Private.TestUtilites RID-agnostic#36207ViktorHofer merged 6 commits intodotnet:masterfrom
Conversation
06c3a5e to
a50f1f0
Compare
a50f1f0 to
ef410f7
Compare
src/CoreFx.Private.TestUtilities/src/System/PlatformDetection.Windows.cs
Outdated
Show resolved
Hide resolved
|
@ericstj is there a way to suppress the mismatch error here? I understand the issue but as we live build the ref which is used for the harvested asset (netcoreapp2.0) that assembly version will always be higher. |
src/System.Net.Http/tests/FunctionalTests/System.Net.Http.Functional.Tests.csproj
Show resolved
Hide resolved
|
@ericstj I added a netcoreapp2.0 ref live build asset because of an AssemblyVersion mismatch between the lib and ref. |
|
@ericstj ok this didn't work well. I now pinned the assembly version to |
Per my above comment don't harvest the lib. When thinking about these packages you should try to imagine the "meaningful" differences in the libraries. I'd assert that netcoreapp2.0 vs netcoreapp (latest) isn't a meaningful distinction since the library isn't adding new API nor is it trying to make use of new API we've added to the framework. As such you shouldn't harvest the netcoreapp2.0 asset as it is the latest meaningfully significant configuration for the library. Also consider that multiple configurations without meaningful differences should be avoided as it bloats the package. If you happen to harvest a lib you need to harvest all refs that might apply to the same framework, so if you harvest netcoreapp2.0 you need to make sure you harvest the netcoreapp2.0 ref and netstandard2.0 ref since neither one is allowed to change as it would make the assembly version greater than the harvested one. This could force you to add a desktop configuration for a ref in some case if you are still live building the desktop impl. That said, I don't think you should do any of that here. |
|
Thanks, that makes perfectly sense. I stopped the netcoreapp2.0 harvesting and will review the pkgprojs when I'm back from holiday. |
21e143b to
1fda7d4
Compare
|
As Microsoft.Win32.Registry is still needed in multiple projects that target netfx I followed the same approach that I took for System.Memory and binplaced the harvested assets. I added ProjectExclusions to not build the project anymore (as it still has a netstandard configuration which would be chosen). Unfortunately it seems that the exclusions break the P2P reference from System.IO.Ports to Microsoft.Win32.Registry when System.IO.Ports targets netstandard instead of netfx (see offline mail thread why it does so during a netfx run). @ericstj thoughts? |
There is no P2P reference. There is a simple name reference and you stopped producing the 'netstandard' ref for Registry. You either need to ensure you still build that or binplace it. Note that binplacing it may be a problem for source build. https://github.com/dotnet/corefx/issues/36451 |
|
Sorry for mixing up terms, you are right this is just a simple name reference. I cherry-picked the configuration fix for System.IO.Pipes ef527a1 into this PR and the error is now gone as in the netfx build the netstandard version of System.IO.Pipes isn't build anymore and therefore it doesn't require the netstandard version of Microsoft.Win32.Registry during the netfx vertical build anymore. |
src/Common/tests/System/Security/Cryptography/AlgorithmImplementations/RSA/EncryptDecrypt.cs
Show resolved
Hide resolved
src/System.Private.Uri/tests/FunctionalTests/UriRelativeResolutionTest.cs
Show resolved
Hide resolved
7dc28ae to
56df45c
Compare
1ee6eb3 to
17d2a6d
Compare
5186004 to
cda7fae
Compare
93f0a80 to
56a055e
Compare
26dbc83 to
6484ef7
Compare
|
@ericstj I factored out the harvesting changes and this now only deals with CoreFx.Private.TestUtilities. Can you please take a look? |
ericstj
left a comment
There was a problem hiding this comment.
Looks reasonable. Thanks for pulling out registry changes.
d50da49 to
8c595ab
Compare
|
OK, VS experience now works with the changes :) |
dotnet@4f0d107 Porting fix over into PlatformDetection.
8c595ab to
3f18465
Compare
bebd61a to
c486166
Compare
* Make CoreFx.Private.TestUtilites RID-agnostic * Add version checks for other distros https://github.com/dotnet/corefx/commit/dotnet/corefx@4f0d10773ccbb4849b869b6a0a73d5938f1804bd Porting fix over into PlatformDetection. * Build test lib in advance for VS support * Disable pretest in AllConfigurations Commit migrated from dotnet/corefx@d3d144f

Changes:
EDIT: Removed the harvesting part from this PR