Skip to content

Commit

Permalink
Add PR check for direct tracing with custom working directory
Browse files Browse the repository at this point in the history
  • Loading branch information
henrymercer committed Jun 11, 2024
1 parent 3f81f8b commit 84eda1c
Show file tree
Hide file tree
Showing 2 changed files with 126 additions and 0 deletions.
92 changes: 92 additions & 0 deletions .github/workflows/__autobuild-direct-tracing-with-working-dir.yml

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

34 changes: 34 additions & 0 deletions pr-checks/checks/autobuild-direct-tracing-with-working-dir.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: "Autobuild direct tracing (custom working directory)"
description: >
An end-to-end integration test of a Java repository built using 'build-mode: autobuild',
with direct tracing enabled and a custom working directory specified as the input to the
autobuild Action.
operatingSystems: ["ubuntu", "windows"]
versions: ["linked", "nightly-latest"]
env:
CODEQL_ACTION_AUTOBUILD_BUILD_MODE_DIRECT_TRACING: true
steps:
- name: Test setup
shell: bash
run: |
# Make sure that Gradle build succeeds in autobuild-dir ...
cp -a ../action/tests/java-repo autobuild-dir
# ... and fails if attempted in the current directory
echo > build.gradle
- uses: ./../action/init
with:
build-mode: autobuild
languages: java
tools: ${{ steps.prepare-test.outputs.tools-url }}
- name: Check that indirect tracing is disabled
shell: bash
run: |
if [[ ! -z "${CODEQL_RUNNER}" ]]; then
echo "Expected indirect tracing to be disabled, but the" \
"CODEQL_RUNNER environment variable is set."
exit 1
fi
- uses: ./../action/autobuild
with:
working-directory: autobuild-dir
- uses: ./../action/analyze

0 comments on commit 84eda1c

Please sign in to comment.