diff --git a/UserManagementAPI/.github/workflows/maven.yml b/UserManagementAPI/.github/workflows/maven.yml new file mode 100644 index 0000000..1c99317 --- /dev/null +++ b/UserManagementAPI/.github/workflows/maven.yml @@ -0,0 +1,25 @@ +name: Run unit tests + +on: + push: + branches: [ "main" ] + +jobs: + build-test-package: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Set up JDK 21 + uses: actions/setup-java@v3 + with: + java-version: '21' + cache: 'maven' + + - name: Build with Maven + run: mvn -B package --file pom.xml + + - name: Run unit tests + run: java -jar target/UserManagementAPI-0.0.1-SNAPSHOT.jar --runTests \ No newline at end of file