[wasm] Standup EnableAgressiveTrimming for library tests (#46367)
* Trim wasm library tests
* Add SystemBuffers HelloTest and only test that
* Import linker from nuget to override sdk linker
* Remove redundant assembly inclusions
* Add WasmTestRunner referenced assemblies
* Add properties to reduce library size
* Updates
* Configure trimming for library tests
* Link assemblies except for test assembly
* Use another path to WasmTestRunner.dll
* Fix typo
* Setup correctly rooted assemblies
* Don't copy WasmTestRunner.dll from wrong patch when using linker
* Don't inflate publish output with packages which are not used for tests runs
* Fix xunit framework files copying to publish location to not overwrite
version copied as part of trimming publish
* Add linker descriptor for xunit code which linker cannot track
* Add tested assembly to the test payload closure
* One more method to preserve
* Preserving some xunit types to make sure we can actually discover the tests
* Put Wasm.targets import in the right spot
* Add a mode where we can run the regular system.buffers tests
* Dont link out Microsoft.DotNet.RemoteExecutor
* Move Microsoft.DotNet.RemoteExecutor inclusion to xml
* Consolidate ConfigureTrimming itemgroups
* Build PrepareForWasmBuildApp before WasmBuildApp
* Remove manual import of WasmTestRunner assemblies
* Remove temporary HelloTest from System.Buffers
* Added flag to not aggressively link by default
* Revert import and build order changes
* Condition trimming related changes on EnableAggressiveTrimming
* Revert "Don't copy WasmTestRunner.dll from wrong patch when using linker" as MainAssembly is back to $(PublishDir)\WasmTestRunner.dll
This reverts commit
79dc240f4c99f61af1a7e4c98d299be25f8f854e.
* Add comment to note temporary RemoteExecutor assembly inclusion
* Move props from general tests to mobile tests
* Revert "Condition trimming related changes on EnableAggressiveTrimming"
This reverts commit
a97fb56eeb47522a4af1e7e47acd3595cf48271e.
* Broaden trimming options for all mobile targets
* Enable PublishTrimmed regardless of OS when aggressively trimming
* Move trimming specific property to ConfigureTrimming
* Import NuGet linker in mobile tests by default
* Add file description
* Add detail to ILLink XML descriptor file
* Reformat ConfigureTrimming target tag
* Fix typo
Co-authored-by: Mitchell Hwang <mitchell.hwang@microsoft.com>
Co-authored-by: Steve Pfister <steve.pfister@microsoft.com>
Co-authored-by: Marek Safar <marek.safar@gmail.com>