From d1f6aa19e620ad309a49a0f27308d438b50379af Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 15 Apr 2026 16:57:05 +0000 Subject: [PATCH 1/4] Update documentation in build.cmd and build.sh for OS targeting and command sync Agent-Logs-Url: https://github.com/dotnet/runtime/sessions/0ff1f33d-17b4-43db-aa5f-b488e6f5f1a5 Co-authored-by: davidwrighton <10779849+davidwrighton@users.noreply.github.com> --- src/tests/build.cmd | 9 ++++++++- src/tests/build.sh | 13 ++++++++++--- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/src/tests/build.cmd b/src/tests/build.cmd index b2d7e5d102a61c..1475a67c196fea 100644 --- a/src/tests/build.cmd +++ b/src/tests/build.cmd @@ -355,9 +355,15 @@ echo All arguments are optional and case-insensitive, and the '-' prefix is opti echo. echo.-? -h --help: View this message. echo. -echo Build architecture: one of "x64", "x86", "arm64" ^(default: x64^). +echo Build architecture: one of "x64", "x86", "arm64", "wasm" ^(default: x64^). echo Build type: one of "Debug", "Checked", "Release" ^(default: Debug^). echo. +echo Build target OS options: +echo os ^: Set the target OS. Common values: windows ^(default^), linux, osx, android, +echo ios, iossimulator, tvos, tvossimulator, maccatalyst, browser, wasi. +echo browser: Shorthand for "os browser" ^(targets WebAssembly in the browser^). +echo wasi: Shorthand for "os wasi" ^(targets WebAssembly System Interface^). +echo. echo -Rebuild: Clean up all test artifacts prior to building tests. echo -SkipRestorePackages: Skip package restore. echo -SkipManaged: Skip the managed tests build. @@ -374,6 +380,7 @@ echo -NativeAOT: Builds the tests for Native AOT compilation. echo -Perfmap: Emit perfmap symbol files when compiling the framework assemblies using Crossgen2. echo -AllTargets: Build managed tests for all target platforms (including test projects in which CLRTestTargetUnsupported resolves to true). echo -ExcludeMonoFailures, Mono: Build the tests for the Mono runtime honoring mono-specific issues. +echo -CoreCLR: Build tests targeting the CoreCLR runtime (default; opposite of -Mono/-ExcludeMonoFailures). echo. echo Set to "" to disable default exclusion file. echo -Priority ^ : specify a set of tests that will be built and run, with priority N. diff --git a/src/tests/build.sh b/src/tests/build.sh index a0709d7386517c..6c14cc78099b36 100755 --- a/src/tests/build.sh +++ b/src/tests/build.sh @@ -136,6 +136,12 @@ build_Tests() usage_list=() usage_list+=("All arguments are optional and the '-' prefix is optional. The options are:") usage_list+=("") +usage_list+=("Build target OS: Use '-os ' (handled by the common build framework) to specify the") +usage_list+=(" target OS. Common values: linux (default on Linux), osx (default on macOS), android,") +usage_list+=(" ios, iossimulator, tvos, tvossimulator, browser, wasi.") +usage_list+=(" For mobile/device targets (android, ios, iossimulator, tvos, tvossimulator), this script") +usage_list+=(" automatically skips building native test components.") +usage_list+=("") usage_list+=("-rebuild - Clean up all test artifacts prior to building tests.") usage_list+=("-skiprestorepackages - Skip package restore.") usage_list+=("-skipmanaged - Skip the managed tests build.") @@ -154,12 +160,13 @@ usage_list+=("-allTargets - Build managed tests for all target platforms (includ usage_list+=("") usage_list+=("-runtests - Run tests after building them.") usage_list+=("-mono, -excludemonofailures - Build the tests for the Mono runtime honoring mono-specific issues.") +usage_list+=("-coreclr - Build tests targeting the CoreCLR runtime (default; opposite of -mono/-excludemonofailures).") usage_list+=("-mono_aot - Use Mono AOT mode.") usage_list+=("-mono_fullaot - Use Mono Full AOT mode.") usage_list+=("") -usage_list+=("-test:xxx - Only build the specified test project ^(relative or absolute project path under src\tests^)."); -usage_list+=("-dir:xxx - Build all test projects in the given directory ^(relative or absolute directory under src\tests^)."); -usage_list+=("-tree:xxx - Build all test projects in the given subtree ^(relative or absolute directory under src\tests^)."); +usage_list+=("-test:xxx - Only build the specified test project (relative or absolute project path under src/tests)."); +usage_list+=("-dir:xxx - Build all test projects in the given directory (relative or absolute directory under src/tests)."); +usage_list+=("-tree:xxx - Build all test projects in the given subtree (relative or absolute directory under src/tests)."); usage_list+=("-log:xxx - Base file name to use for log files (used in lab pipelines that build tests in multiple steps to retain logs for each step).") usage_list+=("") usage_list+=("Any unrecognized arguments will be passed directly to MSBuild.") From c25f0c1796e667b0dcb4e4d9886e2e14d5ce097e Mon Sep 17 00:00:00 2001 From: David Wrighton Date: Thu, 16 Apr 2026 08:13:16 -0700 Subject: [PATCH 2/4] Update src/tests/build.sh Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- src/tests/build.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/tests/build.sh b/src/tests/build.sh index 6c14cc78099b36..4f9877ec2a8d7b 100755 --- a/src/tests/build.sh +++ b/src/tests/build.sh @@ -164,9 +164,9 @@ usage_list+=("-coreclr - Build tests targeting the CoreCLR runtime (default; opp usage_list+=("-mono_aot - Use Mono AOT mode.") usage_list+=("-mono_fullaot - Use Mono Full AOT mode.") usage_list+=("") -usage_list+=("-test:xxx - Only build the specified test project (relative or absolute project path under src/tests)."); -usage_list+=("-dir:xxx - Build all test projects in the given directory (relative or absolute directory under src/tests)."); -usage_list+=("-tree:xxx - Build all test projects in the given subtree (relative or absolute directory under src/tests)."); +usage_list+=("-test:xxx - Only build the specified test project (relative or absolute project path under src/tests).") +usage_list+=("-dir:xxx - Build all test projects in the given directory (relative or absolute directory under src/tests).") +usage_list+=("-tree:xxx - Build all test projects in the given subtree (relative or absolute directory under src/tests).") usage_list+=("-log:xxx - Base file name to use for log files (used in lab pipelines that build tests in multiple steps to retain logs for each step).") usage_list+=("") usage_list+=("Any unrecognized arguments will be passed directly to MSBuild.") From 90e35102deec696c5c15be826c03d0f5b149c972 Mon Sep 17 00:00:00 2001 From: David Wrighton Date: Fri, 17 Apr 2026 03:10:12 -0700 Subject: [PATCH 3/4] Update src/tests/build.sh Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- src/tests/build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tests/build.sh b/src/tests/build.sh index 4f9877ec2a8d7b..f18f28ee740369 100755 --- a/src/tests/build.sh +++ b/src/tests/build.sh @@ -138,7 +138,7 @@ usage_list+=("All arguments are optional and the '-' prefix is optional. The opt usage_list+=("") usage_list+=("Build target OS: Use '-os ' (handled by the common build framework) to specify the") usage_list+=(" target OS. Common values: linux (default on Linux), osx (default on macOS), android,") -usage_list+=(" ios, iossimulator, tvos, tvossimulator, browser, wasi.") +usage_list+=(" ios, iossimulator, tvos, tvossimulator, maccatalyst, browser, wasi.") usage_list+=(" For mobile/device targets (android, ios, iossimulator, tvos, tvossimulator), this script") usage_list+=(" automatically skips building native test components.") usage_list+=("") From 1a27e6794b17ff877c4109c989fcdeb3815d110f Mon Sep 17 00:00:00 2001 From: David Wrighton Date: Mon, 4 May 2026 10:58:26 -0700 Subject: [PATCH 4/4] Update src/tests/build.cmd Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- src/tests/build.cmd | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tests/build.cmd b/src/tests/build.cmd index 1475a67c196fea..1f90861cde5a17 100644 --- a/src/tests/build.cmd +++ b/src/tests/build.cmd @@ -361,8 +361,8 @@ echo. echo Build target OS options: echo os ^: Set the target OS. Common values: windows ^(default^), linux, osx, android, echo ios, iossimulator, tvos, tvossimulator, maccatalyst, browser, wasi. -echo browser: Shorthand for "os browser" ^(targets WebAssembly in the browser^). -echo wasi: Shorthand for "os wasi" ^(targets WebAssembly System Interface^). +echo browser: Shorthand for "os browser" ^(typically combine with "wasm", for example "wasm browser"^). +echo wasi: Shorthand for "os wasi" ^(typically combine with "wasm", for example "wasm wasi"^). echo. echo -Rebuild: Clean up all test artifacts prior to building tests. echo -SkipRestorePackages: Skip package restore.