Skip to content

Commit

Permalink
Merge branch 'main' into henrymercer/update-v1-deprecation-date
Browse files Browse the repository at this point in the history
  • Loading branch information
henrymercer authored Nov 23, 2022
2 parents 6013661 + def4f60 commit 33b2045
Show file tree
Hide file tree
Showing 14 changed files with 89 additions and 98 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/__export-file-baseline-information.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions .github/workflows/__ml-powered-queries.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

34 changes: 33 additions & 1 deletion .github/workflows/__multi-language-autodetect.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

66 changes: 0 additions & 66 deletions .github/workflows/__ruby-autodetect.yml

This file was deleted.

1 change: 0 additions & 1 deletion .github/workflows/__ruby.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions .github/workflows/__swift-autobuild.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions .github/workflows/__swift-custom-build.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions pr-checks/checks/export-file-baseline-information.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: "Export file baseline information"
description: "Tests that file baseline information is exported when the feature is enabled"
versions: ["nightly-latest"]
steps:
- uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9
if: runner.os != 'Windows'
with:
swift-version: "5.7"
- uses: ./../action/init
with:
languages: javascript
Expand Down
4 changes: 2 additions & 2 deletions pr-checks/checks/ml-powered-queries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ steps:
- 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
Expand All @@ -39,7 +39,7 @@ steps:
- name: Check results
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')) }}
SHOULD_RUN_ML_POWERED_QUERIES: ${{ !(matrix.version == 'stable-20220120' && runner.os == 'Windows') }}
shell: bash
run: |
echo "Expecting ML-powered queries to be run: ${SHOULD_RUN_ML_POWERED_QUERIES}"
Expand Down
33 changes: 32 additions & 1 deletion pr-checks/checks/multi-language-autodetect.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,28 @@
name: "Multi-language repository"
description: "An end-to-end integration test of a multi-language repository using automatic language detection"
operatingSystems: ["ubuntu", "macos"]
env:
CODEQL_ENABLE_EXPERIMENTAL_FEATURES_SWIFT: "true" # Remove when Swift is GA.
steps:
- uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9
if: runner.os != 'Windows'
with:
swift-version: "5.7"

- uses: ./../action/init
with:
db-location: "${{ runner.temp }}/customDbLocation"
tools: ${{ steps.prepare-test.outputs.tools-url }}

- name: Build code
shell: bash
run: ./build.sh

- uses: ./../action/analyze
id: analysis
- shell: bash

- name: Check language autodetect for all languages excluding Ruby, Swift
shell: bash
run: |
CPP_DB=${{ fromJson(steps.analysis.outputs.db-locations).cpp }}
if [[ ! -d $CPP_DB ]] || [[ ! $CPP_DB == ${{ runner.temp }}/customDbLocation/* ]]; then
Expand Down Expand Up @@ -43,3 +54,23 @@ steps:
echo "Did not create a database for Python, or created it in the wrong location."
exit 1
fi
- name: Check language autodetect for Ruby
if: "(matrix.version == 'cached' || matrix.version == 'latest' || matrix.version == 'nightly-latest')"
shell: bash
run: |
RUBY_DB=${{ fromJson(steps.analysis.outputs.db-locations).ruby }}
if [[ ! -d $RUBY_DB ]] || [[ ! $RUBY_DB == ${{ runner.temp }}/customDbLocation/* ]]; then
echo "Did not create a database for Ruby, or created it in the wrong location."
exit 1
fi
- name: Check language autodetect for Swift
if: "!startsWith(matrix.os, 'windows') && (matrix.version == 'cached' || matrix.version == 'latest' || matrix.version == 'nightly-latest')"
shell: bash
run: |
SWIFT_DB=${{ fromJson(steps.analysis.outputs.db-locations).swift }}
if [[ ! -d $SWIFT_DB ]] || [[ ! $SWIFT_DB == ${{ runner.temp }}/customDbLocation/* ]]; then
echo "Did not create a database for Swift, or created it in the wrong location."
exit 1
fi
22 changes: 0 additions & 22 deletions pr-checks/checks/ruby-autodetect.yml

This file was deleted.

2 changes: 0 additions & 2 deletions pr-checks/checks/ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ name: "Ruby analysis"
description: "Tests creation of a Ruby database"
versions: ["latest", "cached", "nightly-latest"]
operatingSystems: ["ubuntu", "macos"]
env:
CODEQL_ENABLE_EXPERIMENTAL_FEATURES: "true"
steps:
- uses: ./../action/init
with:
Expand Down
3 changes: 3 additions & 0 deletions pr-checks/checks/swift-autobuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ operatingSystems: ["macos"]
env:
CODEQL_ENABLE_EXPERIMENTAL_FEATURES_SWIFT: "true"
steps:
- uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9
with:
swift-version: "5.7"
- uses: ./../action/init
with:
languages: swift
Expand Down
3 changes: 3 additions & 0 deletions pr-checks/checks/swift-custom-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ env:
CODEQL_ENABLE_EXPERIMENTAL_FEATURES_SWIFT: "true"
DOTNET_GENERATE_ASPNET_CERTIFICATE: "false"
steps:
- uses: swift-actions/setup-swift@5cdaa9161ad1f55ae39a5ea1784ef96de72f95d9
with:
swift-version: "5.7"
- uses: ./../action/init
with:
languages: swift
Expand Down

0 comments on commit 33b2045

Please sign in to comment.