Skip to content

Commit 3bd00e8

Browse files
committed
Add PR checks for other build modes
1 parent 0ab8e2a commit 3bd00e8

File tree

4 files changed

+226
-0
lines changed

4 files changed

+226
-0
lines changed

.github/workflows/__build-mode-autobuild.yml

Lines changed: 82 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.github/workflows/__build-mode-manual.yml

Lines changed: 90 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: "Build mode autobuild"
2+
description: "An end-to-end integration test of a Java repository built using 'build-mode: autobuild'"
3+
operatingSystems: ["ubuntu"]
4+
versions: ["nightly-latest"]
5+
steps:
6+
- uses: ./../action/init
7+
id: init
8+
with:
9+
build-mode: autobuild
10+
db-location: "${{ runner.temp }}/customDbLocation"
11+
languages: java
12+
tools: ${{ steps.prepare-test.outputs.tools-url }}
13+
14+
- name: Validate database build mode
15+
run: |
16+
metadata_path="$RUNNER_TEMP/customDbLocation/java/codeql-database.yml"
17+
build_mode=$(yq eval '.buildMode' "$metadata_path")
18+
if [[ "$build_mode" != "autobuild" ]]; then
19+
echo "Expected build mode to be 'autobuild' but was $build_mode"
20+
exit 1
21+
fi
22+
23+
- uses: ./../action/analyze
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: "Build mode manual"
2+
description: "An end-to-end integration test of a Java repository built using 'build-mode: manual'"
3+
operatingSystems: ["ubuntu"]
4+
versions: ["nightly-latest"]
5+
steps:
6+
- uses: ./../action/init
7+
id: init
8+
with:
9+
build-mode: manual
10+
db-location: "${{ runner.temp }}/customDbLocation"
11+
languages: java
12+
tools: ${{ steps.prepare-test.outputs.tools-url }}
13+
14+
- name: Validate database build mode
15+
run: |
16+
metadata_path="$RUNNER_TEMP/customDbLocation/java/codeql-database.yml"
17+
build_mode=$(yq eval '.buildMode' "$metadata_path")
18+
if [[ "$build_mode" != "manual" ]]; then
19+
echo "Expected build mode to be 'manual' but was $build_mode"
20+
exit 1
21+
fi
22+
23+
- uses: ./../action/.github/actions/setup-swift
24+
with:
25+
codeql-path: ${{ steps.init.outputs.codeql-path }}
26+
27+
- name: Build code
28+
shell: bash
29+
run: ./build.sh
30+
31+
- uses: ./../action/analyze

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy