Skip to content

ci: Simplify tests for verbatim paths #997

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

Merged
merged 2 commits into from
Jul 29, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ jobs:
os: ubuntu-24.04-arm
- target: aarch64-pc-windows-msvc
os: windows-2025
test_verbatim: 1
build_only: 1
- target: arm-unknown-linux-gnueabi
os: ubuntu-24.04
Expand Down Expand Up @@ -92,10 +91,8 @@ jobs:
os: macos-13
- target: i686-pc-windows-msvc
os: windows-2025
test_verbatim: 1
- target: x86_64-pc-windows-msvc
os: windows-2025
test_verbatim: 1
- target: i686-pc-windows-gnu
os: windows-2025
channel: nightly-i686-gnu
Expand All @@ -106,7 +103,6 @@ jobs:
needs: [calculate_vars]
env:
BUILD_ONLY: ${{ matrix.build_only }}
TEST_VERBATIM: ${{ matrix.test_verbatim }}
MAY_SKIP_LIBM_CI: ${{ needs.calculate_vars.outputs.may_skip_libm_ci }}
steps:
- name: Print $HOME
Expand Down Expand Up @@ -166,7 +162,7 @@ jobs:
shell: bash
- run: echo "RUST_COMPILER_RT_ROOT=$(realpath ./compiler-rt)" >> "$GITHUB_ENV"
shell: bash

- name: Download musl source
run: ./ci/update-musl.sh
shell: bash
Expand Down Expand Up @@ -278,7 +274,7 @@ jobs:
with:
name: ${{ env.BASELINE_NAME }}
path: ${{ env.BASELINE_NAME }}.tar.xz

- name: Run wall time benchmarks
run: |
# Always use the same seed for benchmarks. Ideally we should switch to a
Expand Down
9 changes: 6 additions & 3 deletions ci/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,10 @@ else
"${test_builtins[@]}" --benches
"${test_builtins[@]}" --benches --release

if [ "${TEST_VERBATIM:-}" = "1" ]; then
# Validate that having a verbatim path for the target directory works
# (trivial to regress using `/` in paths to build artifacts rather than
# `Path::join`). MinGW does not currently support these paths.
if [[ "$target" = *"windows"* ]] && [[ "$target" != *"gnu"* ]]; then
verb_path=$(cmd.exe //C echo \\\\?\\%cd%\\builtins-test\\target2)
"${test_builtins[@]}" --target-dir "$verb_path" --features c
fi
Expand Down Expand Up @@ -161,7 +164,7 @@ else
mflags+=(--workspace --target "$target")
cmd=(cargo test "${mflags[@]}")
profile_flag="--profile"

# If nextest is available, use that
command -v cargo-nextest && nextest=1 || nextest=0
if [ "$nextest" = "1" ]; then
Expand Down Expand Up @@ -204,7 +207,7 @@ else
"${cmd[@]}" "$profile_flag" release-checked --features unstable-intrinsics --benches

# Ensure that the routines do not panic.
#
#
# `--tests` must be passed because no-panic is only enabled as a dev
# dependency. The `release-opt` profile must be used to enable LTO and a
# single CGU.
Expand Down