diff --git a/.github/workflows/checks-sealights.yaml b/.github/workflows/checks-sealights.yaml index 4c624f977..6c0755254 100644 --- a/.github/workflows/checks-sealights.yaml +++ b/.github/workflows/checks-sealights.yaml @@ -101,7 +101,7 @@ jobs: echo "[Sealights] Configuring SeaLights to scan the pull request branch" echo "Latest commit sha: ${LATEST_COMMIT_SHA}" echo "PR Number: ${PULL_REQUEST_NUMBER}" - ./slcli config create-pr-bsid --app ec-cli --target-branch "main" --pull-request-number ${PULL_REQUEST_NUMBER} --latest-commit ${LATEST_COMMIT_SHA} --repository-url https://github.com/enterprise-contract/ec-cli.git + ./slcli config create-pr-bsid --app nodejs-test --target-branch "ec-cli" --pull-request-number ${PULL_REQUEST_NUMBER} --latest-commit ${LATEST_COMMIT_SHA} --repository-url https://github.com/enterprise-contract/ec-cli.git env: PULL_REQUEST_NUMBER: ${{ github.event.pull_request.number || github.event.issue.number }} LATEST_COMMIT_SHA: ${{github.event.pull_request.head.sha}} @@ -110,7 +110,7 @@ jobs: if: env.on-event == 'push' run: | echo "[Sealights] Configuring SeaLights to scan the main branch after pull request was closed" - ./slcli config create-bsid --app ec-cli --branch main --build ${LATEST_COMMIT_SHA} + ./slcli config create-bsid --app nodejs-test --branch ec-cli --build ${LATEST_COMMIT_SHA} env: LATEST_COMMIT_SHA: ${{ github.sha }} @@ -131,35 +131,37 @@ jobs: path: ${{ github.workspace }} key: workspace-${{ github.run_id }} - Test: - runs-on: ubuntu-latest - needs: Initialize - steps: - - name: Restore workspace - uses: actions/cache@v4 - with: - path: ${{ github.workspace }} - key: workspace-${{ github.run_id }} + # Test: + # runs-on: ubuntu-latest + # needs: Initialize + # steps: + # - name: Restore workspace + # uses: actions/cache@v4 + # with: + # path: ${{ github.workspace }} + # key: workspace-${{ github.run_id }} - - name: Harden Runner - uses: step-security/harden-runner@4d991eb9b905ef189e4c376166672c3f2f230481 # v2.11.0 - with: - egress-policy: audit - disable-telemetry: true + # - name: Harden Runner + # uses: step-security/harden-runner@4d991eb9b905ef189e4c376166672c3f2f230481 # v2.11.0 + # with: + # egress-policy: audit + # disable-telemetry: true - - name: Generate - run: make generate + # - name: Generate + # run: make generate - - name: Test - run: make test + # - name: Test + # run: make test Acceptance: runs-on: ubuntu-latest - needs: [Initialize, Test] + needs: [Initialize] env: BSID: ${{ needs.Initialize.outputs.bsid }} - SEALIGHTS_LOG_LEVEL: none + SEALIGHTS_LOG_LEVEL: debug SEALIGHTS_CONNECTION_TIMEOUT: 120s + SEALIGHTS_LAB_ID: "EC-CLI_Acceptance_Tests_${{ github.repository_owner }}_${{ github.event.number }}" + SEALIGHTS_TEST_STAGE: "Acceptance Tests" steps: - name: Restore workspace uses: actions/cache@v4 @@ -170,15 +172,22 @@ jobs: - name: Update podman run: | "${GITHUB_WORKSPACE}/hack/ubuntu-podman-update.sh" - - name: Create a test session - run: ./slcli test start-stage --bsid=$BSID --testStage "Acceptance Tests" + # - name: Create a test session + # run: ./slcli test start-stage --bsid=$BSID --testStage "Acceptance Tests" - - name: Acceptance test - run: make acceptance-sealights + - name: Second scan + run: | + ./slcli scan --tests-runner --workspacepath "acceptance" --path-to-scanner ./slgoagent --scm git - - name: Upload test results, end test session - if: success() || failure() + - name: Acceptance test + env: + SEALIGHTS_LOG_LEVEL: none run: | - cat ./junit-acceptance.xml - ./slcli test upload-reports --bsid=$BSID --report-location ./junit-acceptance.xml - ./slcli test end-stage --bsid=$BSID --executionId "Acceptance Tests" \ No newline at end of file + make acceptance-sealights + + # - name: Upload test results, end test session + # if: success() || failure() + # run: | + # cat ./junit-acceptance.xml + # ./slcli test upload-reports --bsid=$BSID --report-location ./junit-acceptance.xml + # ./slcli test end-stage --bsid=$BSID --executionId "Acceptance Tests" \ No newline at end of file