From 80c94fdee0a4a146b6a8353088411714182b8e42 Mon Sep 17 00:00:00 2001 From: moi15moi <80980684+moi15moi@users.noreply.github.com> Date: Thu, 25 Jan 2024 20:58:52 -0500 Subject: [PATCH] Update run_test.yml --- .github/workflows/run_test.yml | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/.github/workflows/run_test.yml b/.github/workflows/run_test.yml index 3fccbd8..4afee10 100644 --- a/.github/workflows/run_test.yml +++ b/.github/workflows/run_test.yml @@ -36,7 +36,6 @@ jobs: - name: Install platform-specific requirements (Windows) if: matrix.os == 'windows-latest' - shell: cmd run: | choco install --no-progress --yes mkvtoolnix @@ -44,8 +43,16 @@ jobs: run: | pip install pytest - - name: Run tests + - name: Run tests (Ubuntu && macOS) + if: matrix.os != 'windows-latest' run: | - echo "C:\Program Files\MKVToolNix" >> $GITHUB_PATH - echo "{PATH}={C:\Program Files\MKVToolNix}" >> "$GITHUB_ENV" pytest + + # Problem with the env var on Windows. + # If we don't refresh them in the same step has when we run pytest, mkvtoolnix isn't in the env var + - name: Run tests (Windows) + if: matrix.os == 'windows-latest' + run: | + Import-Module $env:ChocolateyInstall\helpers\chocolateyProfile.psm1 + refreshenv + pytest \ No newline at end of file