diff --git a/.github/workflows/audit.yml b/.github/workflows/audit.yml index 63caa55..8fb03e8 100644 --- a/.github/workflows/audit.yml +++ b/.github/workflows/audit.yml @@ -1,5 +1,9 @@ name: Audit +permissions: + actions: read + contents: read + on: workflow_run: workflows: ["Build"] @@ -26,6 +30,9 @@ jobs: - name: Run npm audit run: npm audit + - name: Wait for artifact to become available + run: sleep 5 + - name: Download code coverage results uses: actions/download-artifact@v4 with: diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7d2d4fc..532ef0c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -45,4 +45,14 @@ jobs: uses: actions/upload-artifact@v4 with: name: code-coverage-report - path: processor/junit-report.xml \ No newline at end of file + path: processor/junit-report.xml + + - name: Confirm Artifact Upload + run: | + echo "Checking for uploaded artifacts..." + if [ ! "$(curl -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" -s https://api.github.com/repos/${{ github.repository }}/actions/artifacts | jq '.artifacts[] | select(.name=="code-coverage-report") | .name')" ]; then + echo "Artifact 'code-coverage-report' not found!" + exit 1 + else + echo "Artifact 'code-coverage-report' found successfully." + fi \ No newline at end of file diff --git a/.github/workflows/testrail.yml b/.github/workflows/testrail.yml index a0c84ab..7e9a525 100644 --- a/.github/workflows/testrail.yml +++ b/.github/workflows/testrail.yml @@ -1,5 +1,9 @@ name: TestRail +permissions: + actions: read + contents: read + on: workflow_run: workflows: ["Build"] @@ -16,6 +20,9 @@ jobs: with: python-version: '3.x' + - name: Wait for artifact to become available + run: sleep 5 + - name: Download code coverage results uses: actions/download-artifact@v4 with: