Skip to content

Commit

Permalink
Integrate merge queue actions
Browse files Browse the repository at this point in the history
  • Loading branch information
smeyer198 committed Nov 14, 2024
1 parent 4aec4e8 commit a5b88ca
Show file tree
Hide file tree
Showing 9 changed files with 153 additions and 75 deletions.
31 changes: 0 additions & 31 deletions .github/workflows/build_analysis.yml

This file was deleted.

60 changes: 60 additions & 0 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Build And Test (Basic)
description: Basic build and tests for the submodules on each push and pull request

on:
push:
pull_request:
types: [opened, reopened]

env:
JAVA_VERSION: 11

jobs:
# Build the CryptoAnalysis module and run its tests
build-and-test-analysis:
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v4
# Sets up Java version
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-package: jdk
java-version: $JAVA_VERSION
# Restores Maven dependecies
- name: Restore local Maven repository
uses: actions/cache@v4
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Run maven command
run: mvn clean verify -DrunAnalysisTests

# Build the HeadlessJavaScanner module and run its tests using Soot
# as the static analysis framework
build-and-test-scanner-soot:
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v4
# Sets up Java version
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-package: jdk
java-version: $JAVA_VERSION
# Restores Maven dependecies
- name: Restore local Maven repository
uses: actions/cache@v4
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Run maven command
run: mvn clean verify -DrunSootTests
32 changes: 0 additions & 32 deletions .github/workflows/build_soot.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/deploy_and_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
fetch-depth: 0

- name: Set up Java
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-package: 'jdk'
Expand Down
33 changes: 30 additions & 3 deletions .github/workflows/merge_queue_mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ name: Build And Test (MacOS)
on:
merge_group:

env:
JAVA_VERSION: 11

jobs:
# This name must be equal to the corresponding build_analysis job
# This name must be equal to the corresponding build_and_test action
build-and-test-analysis:
runs-on: macos-latest
steps:
Expand All @@ -16,7 +19,31 @@ jobs:
with:
distribution: 'adopt'
java-package: jdk
java-version: '11'
java-version: $JAVA_VERSION
# Restores Maven dependecies
- name: Restore local Maven repository
uses: actions/cache@v4
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Run maven command
run: mvn clean verify -DrunAnalysisTests

# This name must be equal to the corresponding build_and_test action
build-and-test-scanner-soot:
runs-on: macos-latest
steps:
- name: Checkout source code
uses: actions/checkout@v4
# Sets up Java version
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-package: jdk
java-version: $JAVA_VERSION
# Restores Maven dependecies
- name: Restore local Maven repository
uses: actions/cache@v4
Expand All @@ -26,4 +53,4 @@ jobs:
restore-keys: |
${{ runner.os }}-maven-
- name: Run maven command
run: mvn clean verify
run: mvn clean verify -DrunSootTests
31 changes: 29 additions & 2 deletions .github/workflows/merge_queue_ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ name: Build And Test (Ubuntu)
on:
merge_group:

env:
JAVA_VERSION: 11

jobs:
# This name must be equal to the corresponding build_analysis job
# This name must be equal to the corresponding build_and_test job
build-and-test-analysis:
runs-on: ubuntu-latest
steps:
Expand All @@ -26,4 +29,28 @@ jobs:
restore-keys: |
${{ runner.os }}-maven-
- name: Run maven command
run: mvn clean verify
run: mvn clean verify -DrunAnalysisTests

# This name must be equal to the corresponding build_and_test job
build-and-test-scanner-soot:
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v4
# Sets up Java version
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-package: jdk
java-version: $JAVA_VERSION
# Restores Maven dependecies
- name: Restore local Maven repository
uses: actions/cache@v4
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Run maven command
run: mvn clean verify -DrunSootTests
31 changes: 29 additions & 2 deletions .github/workflows/merge_queue_windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ name: Build And Test (Windows)
on:
merge_group:

env:
JAVA_VERSION: 11

jobs:
# This name must be equal to the corresponding build_analysis job
# This name must be equal to the corresponding build_and_test job
build-and-test-analysis:
runs-on: windows-latest
steps:
Expand All @@ -26,4 +29,28 @@ jobs:
restore-keys: |
${{ runner.os }}-maven-
- name: Run maven command
run: mvn clean verify
run: mvn clean verify -DrunAnalysisTests

# This name must be equal to the corresponding build_and_test job
build-and-test-scanner-soot:
runs-on: windows-latest
steps:
- name: Checkout source code
uses: actions/checkout@v4
# Sets up Java version
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-package: jdk
java-version: $JAVA_VERSION
# Restores Maven dependecies
- name: Restore local Maven repository
uses: actions/cache@v4
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-
- name: Run maven command
run: mvn clean verify -DrunSootTests
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
name: Test CryptoAnalysis Action
steps:
- name: Checkout source code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Run CogniCrypt
uses: ./
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
# Sets up Java version
- name: Set up Java
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-package: jdk
Expand Down Expand Up @@ -82,7 +82,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
# Semantic versioning
Expand Down

0 comments on commit a5b88ca

Please sign in to comment.