Skip to content

Remove standalone upgrade command #638

Remove standalone upgrade command

Remove standalone upgrade command #638

Workflow file for this run

# PR's only
name: Validate
on:
pull_request:
push:
env:
SLS_IGNORE_WARNING: '*'
FORCE_COLOR: 1
SLS_SCHEMA_CACHE_BASE_DIR: '/home/runner'
jobs:
lint:
name: '[Linux] Node 24: Formatting, lint & packaging tests'
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
fetch-depth: 30
- name: Retrieve last main commit (for `git diff` purposes)
run: |
git checkout -b pr
git fetch --prune --depth=30 origin +refs/heads/main:refs/remotes/origin/main
git checkout main
git checkout pr
- name: Restore npm cache
uses: actions/cache@v5
with:
path: ~/.npm
key: npm-no-lock-v1-${{ runner.os }}-node24-${{ hashFiles('package.json') }}
restore-keys: |
npm-no-lock-v1-${{ runner.os }}-node24-
- name: Install Node.js and npm
uses: actions/setup-node@v6
with:
node-version: 24.x
package-manager-cache: false
- name: Install dependencies
run: npm install --package-lock=false
- name: Validate formatting
run: npm run prettier-check:updated
- name: Validate lint rules
run: npm run lint:updated
- name: Packaging tests
run: npm run integration-test-run-package
- name: Large zip memory smoke test
run: NODE_OPTIONS="--max-old-space-size=256 --expose-gc" SERVERLESS_LARGE_ZIP_SMOKE=1 npx mocha --config test/mocha/unit.cjs test/unit/lib/plugins/package/lib/zip-service.test.js --grep "large zip memory smoke"
linuxNode22:
name: '[Linux] Node 22: Unit tests'
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Restore npm cache
uses: actions/cache@v5
with:
path: ~/.npm
key: npm-no-lock-v1-${{ runner.os }}-node22-${{ hashFiles('package.json') }}
restore-keys: |
npm-no-lock-v1-${{ runner.os }}-node22-
- name: Install Node.js and npm
uses: actions/setup-node@v6
with:
node-version: 22.x
package-manager-cache: false
- name: Install dependencies
run: npm install --package-lock=false
- name: Unit tests
# Some tests depend on TTY support, which is missing in GA runner
# Workaround taken from https://github.com/actions/runner/issues/241#issuecomment-577360161
run: script -e -c "npm test -- -b"
windowsNode22:
name: '[Windows] Node 22: Unit tests'
runs-on: windows-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Restore npm cache
uses: actions/cache@v5
with:
path: ~/.npm
key: npm-no-lock-v1-${{ runner.os }}-node22-${{ hashFiles('package.json') }}
restore-keys: |
npm-no-lock-v1-${{ runner.os }}-node22-
- name: Install Node.js and npm
uses: actions/setup-node@v6
with:
node-version: 22.x
package-manager-cache: false
- name: Install dependencies
run: npm install --package-lock=false
- name: Unit tests
run: npm test -- -b
linuxNode20:
name: '[Linux] Node 20: Unit tests'
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Restore npm cache
uses: actions/cache@v5
with:
path: ~/.npm
key: npm-no-lock-v1-${{ runner.os }}-node20-${{ hashFiles('package.json') }}
restore-keys: |
npm-no-lock-v1-${{ runner.os }}-node20-
- name: Install Node.js and npm
uses: actions/setup-node@v6
with:
node-version: 20.x
package-manager-cache: false
- name: Install dependencies
run: npm install --package-lock=false
- name: Unit tests
# Some tests depend on TTY support, which is missing in GA runner
# Workaround taken from https://github.com/actions/runner/issues/241#issuecomment-577360161
run: script -e -c "npm test -- -b"