diff --git a/.github/workflows/ci-release.yml b/.github/workflows/ci-release.yml index 60e4e4144e207..bd6cbf8ab4f1d 100644 --- a/.github/workflows/ci-release.yml +++ b/.github/workflows/ci-release.yml @@ -162,29 +162,12 @@ jobs: - name: Linux os: ubuntu-latest shell: bash - - name: macOS - os: macos-latest - shell: bash - - name: macOS - os: macos-13 - shell: bash node-version: - 18.17.0 - 18.x - 20.5.0 - 20.x - 22.x - exclude: - - platform: { name: macOS, os: macos-13, shell: bash } - node-version: 18.17.0 - - platform: { name: macOS, os: macos-13, shell: bash } - node-version: 18.x - - platform: { name: macOS, os: macos-13, shell: bash } - node-version: 20.5.0 - - platform: { name: macOS, os: macos-13, shell: bash } - node-version: 20.x - - platform: { name: macOS, os: macos-13, shell: bash } - node-version: 22.x runs-on: ${{ matrix.platform.os }} defaults: run: @@ -221,7 +204,7 @@ jobs: run: ./scripts/smoke-publish-test.sh - name: Conclude Check uses: LouisBrunner/checks-action@v1.6.0 - if: always() + if: steps.create-check.outputs.check-id && always() with: token: ${{ secrets.GITHUB_TOKEN }} conclusion: ${{ job.status }} diff --git a/scripts/smoke-publish-test.sh b/scripts/smoke-publish-test.sh index 871ff6700e232..1d08a0adf2bc8 100755 --- a/scripts/smoke-publish-test.sh +++ b/scripts/smoke-publish-test.sh @@ -86,7 +86,7 @@ node . install -w smoke-tests --ignore-scripts --no-audit --no-fund # debugging locally when we want to pass args to the smoke-tests to limit the # files being run or grep a test, etc. Also now set CI=true so we get more # debug output in our tap tests -CI="true" SMOKE_PUBLISH_NPM="1" SMOKE_PUBLISH_TARBALL="$NPM_TARBALL" npm test \ +CI="true" SMOKE_PUBLISH_TARBALL="$NPM_TARBALL" npm test \ -w smoke-tests \ --ignore-scripts \ - -- -Rtap "$@" + -- "$@" diff --git a/scripts/template-oss/ci-release-yml.hbs b/scripts/template-oss/ci-release-yml.hbs index 9078f02c3429f..8ff869812a331 100644 --- a/scripts/template-oss/ci-release-yml.hbs +++ b/scripts/template-oss/ci-release-yml.hbs @@ -10,12 +10,13 @@ jobCheckout=(obj ref="${{ inputs.ref }}") jobCreateCheck=(obj sha="${{ inputs.check-sha }}") windowsCI=false + macCI=false }} - name: Smoke Publish run: ./scripts/smoke-publish-test.sh - name: Conclude Check uses: LouisBrunner/checks-action@v1.6.0 - if: always() + if: steps.create-check.outputs.check-id && always() with: token: $\{{ secrets.GITHUB_TOKEN }} conclusion: $\{{ job.status }} diff --git a/smoke-tests/test/fixtures/setup.js b/smoke-tests/test/fixtures/setup.js index e4f7dece22d6e..e5302104f2503 100644 --- a/smoke-tests/test/fixtures/setup.js +++ b/smoke-tests/test/fixtures/setup.js @@ -7,7 +7,7 @@ const MockRegistry = require('@npmcli/mock-registry') const http = require('http') const { createProxy } = require('proxy') -const { SMOKE_PUBLISH_NPM, SMOKE_PUBLISH_TARBALL, CI, PATH, Path } = process.env +const { SMOKE_PUBLISH_TARBALL, CI, PATH, Path } = process.env const DEFAULT_REGISTRY = new URL('https://registry.npmjs.org/') const MOCK_REGISTRY = new URL('http://smoke-test-registry.club/') @@ -75,7 +75,7 @@ const getCleanPaths = async () => { module.exports = async (t, { testdir = {}, debug, mockRegistry = true, useProxy = false } = {}) => { const debugLog = debug || CI ? (...a) => t.comment(...a) : () => {} - debugLog({ SMOKE_PUBLISH_NPM, SMOKE_PUBLISH_TARBALL, CI }) + debugLog({ SMOKE_PUBLISH_TARBALL, CI }) const cleanPaths = await getCleanPaths() @@ -219,7 +219,7 @@ module.exports = async (t, { testdir = {}, debug, mockRegistry = true, useProxy const npmLocal = async (...args) => { const [{ force = false }] = getOpts(...args) - if (SMOKE_PUBLISH_NPM && !force) { + if (SMOKE_PUBLISH_TARBALL && !force) { throw new Error('npmLocal cannot be called during smoke-publish') } return baseNpm({ @@ -251,7 +251,7 @@ module.exports = async (t, { testdir = {}, debug, mockRegistry = true, useProxy return { npmPath, npmLocal, - npm: SMOKE_PUBLISH_NPM ? npmPath : npm, + npm: SMOKE_PUBLISH_TARBALL ? npmPath : npm, spawn: baseSpawn, readFile, getPath, @@ -269,6 +269,6 @@ module.exports.testdir = testdirHelper module.exports.getNpmRoot = getNpmRoot module.exports.CLI_ROOT = CLI_ROOT module.exports.WINDOWS = WINDOWS -module.exports.SMOKE_PUBLISH = !!SMOKE_PUBLISH_NPM +module.exports.SMOKE_PUBLISH = !!SMOKE_PUBLISH_TARBALL module.exports.SMOKE_PUBLISH_TARBALL = SMOKE_PUBLISH_TARBALL module.exports.MOCK_REGISTRY = MOCK_REGISTRY