Use runner.os in ML-powered queries tests too

This commit is contained in:
Henry Mercer 2022-11-22 20:45:26 +00:00
parent c49c05b5df
commit 34d91a9ce7
2 changed files with 4 additions and 5 deletions

View file

@ -87,8 +87,7 @@ jobs:
- name: Check sarif
uses: ./../action/.github/check-sarif
# Running on Windows requires CodeQL CLI 2.9.0+.
if: "!(matrix.version == 'stable-20220120' && (matrix.os == 'windows-latest'\
\ || matrix.os == 'windows-2019'))"
if: "!(matrix.version == 'stable-20220120' && runner.os == 'Windows')"
with:
sarif-file: ${{ runner.temp }}/results/javascript.sarif
queries-run: js/ml-powered/nosql-injection,js/ml-powered/path-injection,js/ml-powered/sql-injection,js/ml-powered/xss
@ -98,7 +97,7 @@ jobs:
env:
# Running on Windows requires CodeQL CLI 2.9.0+.
SHOULD_RUN_ML_POWERED_QUERIES: ${{ !(matrix.version == 'stable-20220120' &&
(matrix.os == 'windows-latest' || matrix.os == 'windows-2019')) }}
runner.os == 'Windows') }}
shell: bash
run: |
echo "Expecting ML-powered queries to be run: ${SHOULD_RUN_ML_POWERED_QUERIES}"