-
Notifications
You must be signed in to change notification settings - Fork 830
Refactor component test compilation #14747
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
Conversation
1b13d00 to
77e57d4
Compare
| /Z.fs | ||
| /Y.fs | ||
| /X.fs | ||
| /Library.fs | ||
| /Ghost.fs | ||
| /D.fsi | ||
| /D.fs | ||
| /C.fsi | ||
| /C.fs | ||
| /B.fsi | ||
| /B.fs | ||
| /A.fsi | ||
| /A.fs |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should those be removed?
| let systemDynamicRuntimeRef = lazy AssemblyMetadata.CreateFromImage(TestResources.NetFX.netstandard20.System_Dynamic_Runtime).GetReference(display = "System.Dynamic.Runtime.dll (netstandard 2.0 ref)") | ||
|
|
||
|
|
||
| module private NetCoreApp31Refs = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we still use netcoreapp31 somewhere?
| let asNetStandard20 (cUnit: CompilationUnit) : CompilationUnit = | ||
| match cUnit with | ||
| | FS fs -> FS { fs with TargetFramework = TargetFramework.NetStandard20 } | ||
| | CS cs -> CS { cs with TargetFramework = TargetFramework.NetStandard20 } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Curious - does it work with C# tests too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not yet, when I need it for C# I will make it work.
This allows the TargetFramework for compilation in the test framework to be configured.
It is necessary because the current mechanism uses #if/#else/#endif to hard code the framework references based on the TFM of the test build. However, we should be able to compile other tfms for example Netstandard2.0