-
-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into fix/conf_dirs
- Loading branch information
Showing
194 changed files
with
2,675 additions
and
3,341 deletions.
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
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
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 |
---|---|---|
|
@@ -8,6 +8,7 @@ on: | |
|
||
permissions: | ||
contents: read | ||
statuses: write | ||
|
||
jobs: | ||
build: | ||
|
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 |
---|---|---|
@@ -0,0 +1,26 @@ | ||
name: "E2E: Suite run" | ||
on: | ||
workflow_dispatch: | ||
inputs: | ||
test_suite: | ||
description: 'Select test suite to run' | ||
default: 'regression' | ||
required: true | ||
type: choice | ||
options: | ||
- regression | ||
- sanity | ||
- smoke | ||
|
||
permissions: | ||
contents: read | ||
checks: write | ||
statuses: write | ||
|
||
jobs: | ||
build-and-test: | ||
uses: ./.github/workflows/e2e-run.yml | ||
secrets: inherit | ||
with: | ||
suite_name: ${{ github.event.inputs.test_suite }} | ||
sha: ${{ github.sha }} |
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 |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: "E2E: PR smoke tests" | ||
on: | ||
pull_request: | ||
types: [ "opened", "reopened", "synchronize" ] | ||
paths: | ||
- "pom.xml" | ||
- "contract/**" | ||
- "api/**" | ||
- "serde-api/**" | ||
- "frontend/**" | ||
- "e2e-tests/**" | ||
|
||
permissions: | ||
contents: read | ||
checks: write | ||
statuses: write | ||
|
||
jobs: | ||
build-and-test: | ||
uses: ./.github/workflows/e2e-run.yml | ||
secrets: inherit | ||
with: | ||
suite_name: "smoke" | ||
sha: ${{ github.event.pull_request.head.sha }} |
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 |
---|---|---|
@@ -0,0 +1,164 @@ | ||
name: "E2E: Run tests" | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
suite_name: | ||
description: 'Test suite name to run' | ||
default: 'regression' | ||
required: true | ||
type: string | ||
sha: | ||
required: true | ||
type: string | ||
|
||
permissions: | ||
contents: read | ||
checks: write | ||
statuses: write | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
token: ${{ github.token }} | ||
ref: ${{ inputs.sha }} | ||
|
||
- name: Set up JDK | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '17' | ||
distribution: 'zulu' | ||
cache: 'maven' | ||
|
||
- name: Build with Maven | ||
id: build_app | ||
run: | | ||
./mvnw -B -ntp versions:set -DnewVersion=${{ inputs.sha }} | ||
./mvnw -B -V -ntp clean install -Pprod -Dmaven.test.skip=true | ||
- name: Upload maven artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: artifacts | ||
path: ~/.m2/repository/io/kafbat/ui/**/* | ||
retention-days: 7 | ||
|
||
- name: Dump docker image | ||
run: | | ||
docker image save ghcr.io/kafbat/kafka-ui:latest > /tmp/image.tar | ||
- name: Upload docker image | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: image | ||
path: /tmp/image.tar | ||
retention-days: 7 | ||
|
||
tests: | ||
runs-on: ubuntu-latest | ||
needs: build | ||
steps: | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
token: ${{ github.token }} | ||
ref: ${{ inputs.sha }} | ||
|
||
- name: Set up JDK | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '17' | ||
distribution: 'zulu' | ||
cache: 'maven' | ||
|
||
- name: Download maven artifacts | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: artifacts | ||
path: ~/.m2/repository/io/kafbat/ui | ||
|
||
- name: Download docker image | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: image | ||
path: /tmp | ||
|
||
- name: Load Docker image | ||
run: | | ||
docker load --input /tmp/image.tar | ||
- name: Cache Docker images. | ||
uses: ScribeMD/[email protected] | ||
with: | ||
key: docker-${{ runner.os }}-${{ hashFiles('./e2e-tests/selenoid/selenoid-ci.yaml', './documentation/compose/e2e-tests.yaml') }} | ||
|
||
- name: Compose up | ||
id: compose_app | ||
# use the following command until #819 will be fixed # TODO recheck 819 | ||
run: | | ||
mkdir -p ./e2e-tests/target/selenoid-results/video | ||
mkdir -p ./e2e-tests/target/selenoid-results/logs | ||
docker-compose -f ./e2e-tests/selenoid/selenoid-ci.yaml up -d | ||
docker-compose -f ./documentation/compose/e2e-tests.yaml up -d | ||
- name: Dump Docker logs on failure | ||
if: failure() | ||
uses: jwalton/[email protected] | ||
|
||
- name: Run test suite | ||
run: | | ||
./mvnw -B -ntp versions:set -DnewVersion=${{ inputs.sha }} | ||
./mvnw -B -V -ntp -Dsurefire.suiteXmlFiles='src/test/resources/${{ inputs.suite_name }}.xml' -f 'e2e-tests' test -Pprod | ||
- name: Upload allure reports artifact | ||
if: '!cancelled()' | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: reports | ||
path: ./e2e-tests/target/allure-results | ||
retention-days: 7 | ||
|
||
reports: | ||
runs-on: ubuntu-latest | ||
needs: tests | ||
if: ${{ !cancelled() && github.repository == 'kafbat/kafka-ui' }} | ||
steps: | ||
- name: Download allure reports artifact | ||
uses: actions/download-artifact@v4 | ||
with: | ||
name: reports | ||
path: ./e2e-tests/target/allure-results | ||
|
||
- name: Generate Allure report | ||
uses: simple-elf/[email protected] | ||
id: allure-report | ||
with: | ||
allure_results: ./e2e-tests/target/allure-results | ||
gh_pages: allure-results | ||
allure_report: allure-report | ||
subfolder: allure-results | ||
report_url: "https://reports.kafbat.dev" | ||
|
||
- name: Upload allure report to R2 | ||
uses: ryand56/r2-upload-action@latest | ||
with: | ||
source-dir: allure-history/allure-results | ||
destination-dir: . | ||
r2-bucket: "reports" | ||
r2-account-id: ${{ secrets.R2_ACCOUNT_ID }} | ||
r2-access-key-id: ${{ secrets.R2_ACCESS_KEY_ID }} | ||
r2-secret-access-key: ${{ secrets.R2_ACCESS_SECRET_KEY }} | ||
|
||
- name: Add allure link status check | ||
uses: Sibz/[email protected] | ||
with: | ||
authToken: ${{secrets.GITHUB_TOKEN}} | ||
context: "Click Details button to view Allure report" | ||
state: "success" | ||
sha: ${{ inputs.sha }} | ||
target_url: https://reports.kafbat.dev/${{ github.run_number }} |
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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
name: "E2E: Weekly suite" | ||
on: | ||
schedule: | ||
- cron: '0 1 * * 1' | ||
|
||
permissions: | ||
contents: read | ||
checks: write | ||
statuses: write | ||
|
||
jobs: | ||
build-and-test: | ||
uses: ./.github/workflows/e2e-run.yml | ||
secrets: inherit | ||
with: | ||
suite_name: "sanity" | ||
sha: ${{ github.sha }} |
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
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
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
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
Oops, something went wrong.