diff --git a/.github/workflows/reporter.yml b/.github/workflows/reporter.yml new file mode 100644 index 000000000..b43f3a166 --- /dev/null +++ b/.github/workflows/reporter.yml @@ -0,0 +1,35 @@ +name: Upload results to Ibutsu +on: + workflow_dispatch: +# pull_request: +# branches: +# - master +# types: +# [closed] +# workflow_dispatch: +jobs: + upload: + if: | + contains(github.event.pull_request.labels.*.name, 'release') || + contains(github.event.pull_request.labels.*.name, 'release minor') + runs-on: ubuntu-latest + steps: + - name: Check out repository code + uses: actions/checkout@v4 + - name: Install required dependencies + run: npm ci + - name: Run the tests + run: cd ${{ github.workspace }}/packages/components && npm run test:ct && npx merge-results -c cypress.config.ts + - name: Login to Quay + uses: docker/login-action@v3 + with: + registry: quay.io + username: ${{ secrets.QUAY_USERNAME }} + password: ${{ secrets.QUAY_PASSWORD }} + - name: Pull the uploader image + run: podman pull quay.io/cloudservices/iqe-artifact-uploader-s3:latest + - name: Upload the results + run: | + podman run -e AWS_BUCKET=${{ secrets.AWS_BUCKET }} -e AWS_REGION=${{ secrets.AWS_REGION }} \ + -e AWS_SECRET_ACCESS_KEY=${{ secrets.AWS_SECRET_ACCESS_KEY }} -e AWS_ACCESS_KEY_ID=${{ secrets.AWS_ACCESS_KEY_ID }} \ + -v ${{ github.workspace }}/ibutsu-report:/results quay.io/cloudservices/iqe-artifact-uploader-s3:latest . diff --git a/package-lock.json b/package-lock.json index 6504fda28..7ba875daf 100644 --- a/package-lock.json +++ b/package-lock.json @@ -99,7 +99,7 @@ "jest-canvas-mock": "^2.4.0", "jest-environment-jsdom": "^29.6.2", "lerna": "^5.6.2", - "mocha-ibutsu-reporter": "^0.0.1", + "mocha-ibutsu-reporter": "^0.0.2", "mutation-observer": "^1.0.3", "node-sass-package-importer": "^5.3.2", "prettier": "^2.7.1", @@ -30199,14 +30199,15 @@ } }, "node_modules/mocha-ibutsu-reporter": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/mocha-ibutsu-reporter/-/mocha-ibutsu-reporter-0.0.1.tgz", - "integrity": "sha512-MN3pt5i/mUxOvwBfQc5KzPM2J2thqHwTabL50HVoL/OhBr6udTVYweKtS/D5MeQhQRQ7WKTTjpDUhXZRihdHqg==", + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/mocha-ibutsu-reporter/-/mocha-ibutsu-reporter-0.0.2.tgz", + "integrity": "sha512-wpT3N3KhO2wnpyr/t9V833y2ApDrHPtNpJ+iS3rKD8frf8cMzX5g4sSvXyXwOOJ8ylyCk4zDqhW8fBniiqfwOA==", "dev": true, "dependencies": { "commander": "^10.0.0", "md5": "^2.3.0", "mkdirp": "^2.1.3", + "uuid": "^9.0.0", "xml": "^1.0.0", "xml-js": "^1.6.11" }, @@ -30241,6 +30242,19 @@ "url": "https://github.com/sponsors/isaacs" } }, + "node_modules/mocha-ibutsu-reporter/node_modules/uuid": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", + "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==", + "dev": true, + "funding": [ + "https://github.com/sponsors/broofa", + "https://github.com/sponsors/ctavan" + ], + "bin": { + "uuid": "dist/bin/uuid" + } + }, "node_modules/mocha/node_modules/ansi-colors": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", @@ -43650,7 +43664,7 @@ }, "packages/types": { "name": "@redhat-cloud-services/types", - "version": "1.0.5", + "version": "1.0.6", "license": "Apache-2.0", "devDependencies": { "@patternfly/quickstarts": "^5.0.0", @@ -66523,14 +66537,15 @@ } }, "mocha-ibutsu-reporter": { - "version": "0.0.1", - "resolved": "https://registry.npmjs.org/mocha-ibutsu-reporter/-/mocha-ibutsu-reporter-0.0.1.tgz", - "integrity": "sha512-MN3pt5i/mUxOvwBfQc5KzPM2J2thqHwTabL50HVoL/OhBr6udTVYweKtS/D5MeQhQRQ7WKTTjpDUhXZRihdHqg==", + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/mocha-ibutsu-reporter/-/mocha-ibutsu-reporter-0.0.2.tgz", + "integrity": "sha512-wpT3N3KhO2wnpyr/t9V833y2ApDrHPtNpJ+iS3rKD8frf8cMzX5g4sSvXyXwOOJ8ylyCk4zDqhW8fBniiqfwOA==", "dev": true, "requires": { "commander": "^10.0.0", "md5": "^2.3.0", "mkdirp": "^2.1.3", + "uuid": "^9.0.0", "xml": "^1.0.0", "xml-js": "^1.6.11" }, @@ -66546,6 +66561,12 @@ "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-2.1.6.tgz", "integrity": "sha512-+hEnITedc8LAtIP9u3HJDFIdcLV2vXP33sqLLIzkv1Db1zO/1OxbvYf0Y1OC/S/Qo5dxHXepofhmxL02PsKe+A==", "dev": true + }, + "uuid": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", + "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==", + "dev": true } } }, diff --git a/package.json b/package.json index 84a5b119b..58698604a 100644 --- a/package.json +++ b/package.json @@ -107,7 +107,7 @@ "jest-canvas-mock": "^2.4.0", "jest-environment-jsdom": "^29.6.2", "lerna": "^5.6.2", - "mocha-ibutsu-reporter": "^0.0.1", + "mocha-ibutsu-reporter": "^0.0.2", "mutation-observer": "^1.0.3", "node-sass-package-importer": "^5.3.2", "prettier": "^2.7.1",