Skip to content

Commit

Permalink
Add test workflow for Student Submission, which can be used for pre-c…
Browse files Browse the repository at this point in the history
…ompile tests etc.
  • Loading branch information
sarpsahinalp committed Aug 3, 2024
1 parent 50c2f40 commit 9577966
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 17 deletions.
44 changes: 27 additions & 17 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,30 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: Checkout Repository
uses: actions/checkout@v2

- name: Set up JDK 21
uses: actions/setup-java@v3
with:
java-version: '21'
distribution: 'adopt'

- name: Install Maven
run: |
sudo rm -rf /usr/bin/mvn
sudo wget -q -O - "https://apache.osuosl.org/maven/maven-3/3.9.8/binaries/apache-maven-3.9.8-bin.tar.gz" | sudo tar xzf - -C /usr/share
sudo ln -s /usr/share/apache-maven-3.9.8/bin/mvn /usr/bin/mvn
- name: Build with Maven
run: mvn -B package --file pom.xml
- name: Checkout Repository
uses: actions/checkout@v2

- name: Set up JDK 21
uses: actions/setup-java@v3
with:
java-version: '21'
distribution: 'adopt'

- name: Install Maven
run: |
sudo rm -rf /usr/bin/mvn
sudo wget -q -O - "https://apache.osuosl.org/maven/maven-3/3.9.8/binaries/apache-maven-3.9.8-bin.tar.gz" | sudo tar xzf - -C /usr/share
sudo ln -s /usr/share/apache-maven-3.9.8/bin/mvn /usr/bin/mvn
- name: Build and Test with Maven
run: mvn -B package --file pom.xml

- name: Run Tests on Student Submission
run: |
git config --global url.https://github.com/.insteadOf git://github.com/
git clone https://github.com/sarpsahinalp/test-student-submission.git
mkdir test-student-submission/libs
cp target/*.jar test-student-submission/libs
cd test-student-submission
./gradlew build
./gradlew test
1 change: 1 addition & 0 deletions src/main/resources/logback.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
</encoder>
</appender>

<logger name="com.tngtech.archunit" level="INFO" />
<root level="debug">
<appender-ref ref="STDOUT" />
</root>
Expand Down

0 comments on commit 9577966

Please sign in to comment.