forked from alexandru-slobodcicov/liquibase-mongodb
-
Notifications
You must be signed in to change notification settings - Fork 47
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* consume packages from GPM * add env variables and profile for CORE and PRO in pom * Update test.yml --------- Co-authored-by: Sayali M <sayali@Sayalis-MacBook-Pro>
- Loading branch information
1 parent
abfe081
commit 029bef9
Showing
2 changed files
with
214 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,11 @@ jobs: | |
build: | ||
name: Build & Package | ||
runs-on: ubuntu-latest | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
LIQUIBOT_TOKEN: ${{ secrets.LIQUIBOT_PAT }} | ||
GPM_USERNAME: "liquibot" | ||
GPM_PASSWORD: ${{ secrets.PUBLIC_REPO_ACCESS_TOKEN }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
|
@@ -21,6 +26,48 @@ jobs: | |
java-version: 17 | ||
distribution: 'temurin' | ||
cache: 'maven' | ||
# look for dependencies in maven | ||
- name: maven-settings-xml-action | ||
uses: whelk-io/maven-settings-xml-action@v21 | ||
with: | ||
repositories: | | ||
[ | ||
{ | ||
"id": "liquibase", | ||
"url": "https://maven.pkg.github.com/liquibase/liquibase", | ||
"releases": { | ||
"enabled": "false" | ||
}, | ||
"snapshots": { | ||
"enabled": "true", | ||
"updatePolicy": "always" | ||
} | ||
}, | ||
{ | ||
"id": "liquibase-pro", | ||
"url": "https://maven.pkg.github.com/liquibase/liquibase-pro", | ||
"releases": { | ||
"enabled": "false" | ||
}, | ||
"snapshots": { | ||
"enabled": "true", | ||
"updatePolicy": "always" | ||
} | ||
} | ||
] | ||
servers: | | ||
[ | ||
{ | ||
"id": "liquibase-pro", | ||
"username": "liquibot", | ||
"password": "${{ secrets.LIQUIBOT_PAT }}" | ||
}, | ||
{ | ||
"id": "liquibase", | ||
"username": "liquibot", | ||
"password": "${{ secrets.LIQUIBOT_PAT }}" | ||
} | ||
] | ||
- name: Build and Package | ||
run: mvn -B dependency:go-offline clean package -DskipTests=true | ||
|
@@ -53,6 +100,9 @@ jobs: | |
os: [ ubuntu-latest, windows-latest ] | ||
name: Test Java ${{ matrix.java }} - ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
env: | ||
LIQUIBOT_TOKEN: ${{ secrets.LIQUIBOT_PAT }} | ||
GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }} | ||
needs: build | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
@@ -64,6 +114,49 @@ jobs: | |
distribution: 'temurin' | ||
cache: 'maven' | ||
|
||
# look for dependencies in maven | ||
- name: maven-settings-xml-action | ||
uses: whelk-io/maven-settings-xml-action@v21 | ||
with: | ||
repositories: | | ||
[ | ||
{ | ||
"id": "liquibase", | ||
"url": "https://maven.pkg.github.com/liquibase/liquibase", | ||
"releases": { | ||
"enabled": "false" | ||
}, | ||
"snapshots": { | ||
"enabled": "true", | ||
"updatePolicy": "always" | ||
} | ||
}, | ||
{ | ||
"id": "liquibase-pro", | ||
"url": "https://maven.pkg.github.com/liquibase/liquibase-pro", | ||
"releases": { | ||
"enabled": "false" | ||
}, | ||
"snapshots": { | ||
"enabled": "true", | ||
"updatePolicy": "always" | ||
} | ||
} | ||
] | ||
servers: | | ||
[ | ||
{ | ||
"id": "liquibase-pro", | ||
"username": "liquibot", | ||
"password": "${{ secrets.LIQUIBOT_PAT }}" | ||
}, | ||
{ | ||
"id": "liquibase", | ||
"username": "liquibot", | ||
"password": "${{ secrets.LIQUIBOT_PAT }}" | ||
} | ||
] | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: ${{needs.build.outputs.artifact_id}}-artifacts | ||
|
@@ -84,6 +177,9 @@ jobs: | |
integration-tests: | ||
name: Integration Test - Java ${{ matrix.java }} | ||
runs-on: ubuntu-latest | ||
env: | ||
LIQUIBOT_TOKEN: ${{ secrets.LIQUIBOT_PAT }} | ||
GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }} | ||
needs: unit-test | ||
strategy: | ||
matrix: | ||
|
@@ -104,12 +200,60 @@ jobs: | |
java-version: ${{ matrix.java }} | ||
distribution: 'temurin' | ||
cache: 'maven' | ||
|
||
# look for dependencies in maven | ||
- name: maven-settings-xml-action | ||
uses: whelk-io/maven-settings-xml-action@v21 | ||
with: | ||
repositories: | | ||
[ | ||
{ | ||
"id": "liquibase", | ||
"url": "https://maven.pkg.github.com/liquibase/liquibase", | ||
"releases": { | ||
"enabled": "false" | ||
}, | ||
"snapshots": { | ||
"enabled": "true", | ||
"updatePolicy": "always" | ||
} | ||
}, | ||
{ | ||
"id": "liquibase-pro", | ||
"url": "https://maven.pkg.github.com/liquibase/liquibase-pro", | ||
"releases": { | ||
"enabled": "false" | ||
}, | ||
"snapshots": { | ||
"enabled": "true", | ||
"updatePolicy": "always" | ||
} | ||
} | ||
] | ||
servers: | | ||
[ | ||
{ | ||
"id": "liquibase-pro", | ||
"username": "liquibot", | ||
"password": "${{ secrets.LIQUIBOT_PAT }}" | ||
}, | ||
{ | ||
"id": "liquibase", | ||
"username": "liquibot", | ||
"password": "${{ secrets.LIQUIBOT_PAT }}" | ||
} | ||
] | ||
- name: Integration Test - Java ${{ matrix.java }} | ||
run: mvn -B clean test verify -Prun-its --file pom.xml | ||
|
||
harness-tests: | ||
name: Harness Tests - Java ${{ matrix.java }} | ||
runs-on: ubuntu-latest | ||
env: | ||
LIQUIBOT_TOKEN: ${{ secrets.LIQUIBOT_PAT }} | ||
GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }} | ||
strategy: | ||
matrix: | ||
java: [ 11, 17 ] | ||
|
@@ -124,6 +268,49 @@ jobs: | |
distribution: 'temurin' | ||
cache: 'maven' | ||
|
||
# look for dependencies in maven | ||
- name: maven-settings-xml-action | ||
uses: whelk-io/maven-settings-xml-action@v21 | ||
with: | ||
repositories: | | ||
[ | ||
{ | ||
"id": "liquibase", | ||
"url": "https://maven.pkg.github.com/liquibase/liquibase", | ||
"releases": { | ||
"enabled": "false" | ||
}, | ||
"snapshots": { | ||
"enabled": "true", | ||
"updatePolicy": "always" | ||
} | ||
}, | ||
{ | ||
"id": "liquibase-pro", | ||
"url": "https://maven.pkg.github.com/liquibase/liquibase-pro", | ||
"releases": { | ||
"enabled": "false" | ||
}, | ||
"snapshots": { | ||
"enabled": "true", | ||
"updatePolicy": "always" | ||
} | ||
} | ||
] | ||
servers: | | ||
[ | ||
{ | ||
"id": "liquibase-pro", | ||
"username": "liquibot", | ||
"password": "${{ secrets.LIQUIBOT_PAT }}" | ||
}, | ||
{ | ||
"id": "liquibase", | ||
"username": "liquibot", | ||
"password": "${{ secrets.LIQUIBOT_PAT }}" | ||
} | ||
] | ||
- name: Build Cache | ||
uses: actions/[email protected] | ||
with: | ||
|
@@ -149,4 +336,4 @@ jobs: | |
uses: actions/upload-artifact@v3 | ||
with: | ||
name: mongodb-test-results | ||
path: build/spock-reports | ||
path: build/spock-reports |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters