From c39bd46bc937098819f682057170ac94f9ccbddb Mon Sep 17 00:00:00 2001 From: Andrei Horodniceanu Date: Sun, 6 Jul 2025 13:44:17 +0300 Subject: [PATCH 1/3] rdmd_test.d: Fix test failure a51571a0bb8a963591c38a338d42216202f03556 changed the help text output leading leading to test failures Signed-off-by: Andrei Horodniceanu --- rdmd_test.d | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rdmd_test.d b/rdmd_test.d index 881569887..626f510cf 100755 --- a/rdmd_test.d +++ b/rdmd_test.d @@ -140,12 +140,12 @@ void runCompilerAgnosticTests(string rdmdApp, string defaultCompiler, string mod /* Test help string output when no arguments passed. */ auto res = execute([rdmdApp]); enforce(res.status == 1, res.output); - enforce(res.output.canFind("Usage: rdmd [RDMD AND DMD OPTIONS]... program [PROGRAM OPTIONS]...")); + enforce(res.output.canFind("Usage: rdmd [RDMD AND DMD OPTIONS...] program [PROGRAM OPTIONS...]")); /* Test --help. */ res = execute([rdmdApp, "--help"]); enforce(res.status == 0, res.output); - enforce(res.output.canFind("Usage: rdmd [RDMD AND DMD OPTIONS]... program [PROGRAM OPTIONS]...")); + enforce(res.output.canFind("Usage: rdmd [RDMD AND DMD OPTIONS...] program [PROGRAM OPTIONS...]")); string helpText = res.output; From b656bd6cd4c51b4513605aeb52d7c771c9fdcecf Mon Sep 17 00:00:00 2001 From: Andrei Horodniceanu Date: Sun, 6 Jul 2025 13:57:58 +0300 Subject: [PATCH 2/3] CI: refactor shell-bash requirement Signed-off-by: Andrei Horodniceanu --- .github/workflows/main.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 24ed8bf35..2d336234d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -9,6 +9,9 @@ concurrency: jobs: main: + defaults: + run: + shell: bash strategy: fail-fast: false matrix: @@ -27,12 +30,9 @@ jobs: with: compiler: ${{ matrix.dc }} - name: Build - shell: bash run: make -j$N DMD=$DMD - name: Test - shell: bash run: make -j$N DMD=$DMD test - name: 'Windows: Build and test with MODEL=32' if: runner.os == 'Windows' - shell: bash run: make -j$N DMD=$DMD MODEL=32 all test From 38ea11e86136fa3627ec0ca088cdb3b92f734a3b Mon Sep 17 00:00:00 2001 From: Andrei Horodniceanu Date: Sun, 6 Jul 2025 14:03:45 +0300 Subject: [PATCH 3/3] CI: bump setup-dlang to v2 Signed-off-by: Andrei Horodniceanu --- .github/workflows/main.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2d336234d..c4f7019b8 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -21,14 +21,19 @@ jobs: runs-on: ${{ matrix.os }} timeout-minutes: 10 env: - DMD: ${{ startsWith(matrix.dc, 'ldc') && 'ldmd2' || 'dmd' }} N: ${{ startsWith(matrix.os, 'macos') && '3' || '2' }} steps: - uses: actions/checkout@v4 - name: Install D compiler - uses: dlang-community/setup-dlang@v1.3.0 + uses: dlang-community/setup-dlang@v2 with: compiler: ${{ matrix.dc }} + # rdmd_test.d needs this + - name: Set DMD to its basename without extension + run: | + val=$(basename "${DMD}") + val=${val%.*} + tee -a ${GITHUB_ENV} <<<"DMD=${val}" - name: Build run: make -j$N DMD=$DMD - name: Test