Skip to content

[SECRES-4132] Bugfix: npm installation target resolution #633

[SECRES-4132] Bugfix: npm installation target resolution

[SECRES-4132] Bugfix: npm installation target resolution #633

Workflow file for this run

name: test
on:
push:
branches:
- main
pull_request:
branches:
- main
permissions:
contents: read
jobs:
cli:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Install Supply-Chain Firewall
run: pip install .
- name: Test firewall CLI
run: make test-cli
configure:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Install Supply-Chain Firewall
run: pip install .
- name: Test firewall configure script
run: make test-configure
python-executable:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Install Supply-Chain Firewall
run: pip install .
- name: Test Python executable in the global environment
run: make test-python-executable
- name: Test Python executable in a virtual environment
run: |
python -m venv venv
source venv/bin/activate
make test-python-executable
pip-integration:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
pip-version: ["22.2", "22.3", "23.0", "23.1", "23.2", "23.3", "24.0", "24.1", "24.2", "24.3", "25.0", "25.1", "25.2", "25.3"]
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install pip==${{ matrix.pip-version }}
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Install Supply-Chain Firewall
run: pip install .
- name: Test firewall pip integration
run: |
make test-pip
make test-pip-class
poetry-integration:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
poetry-version: ["1.7.0", "1.8.0", "2.0.0", "2.1.0", "2.2.0"]
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install Poetry
run: |
pip install poetry==${{ matrix.poetry-version }}
if [ "${{ matrix.poetry-version }}" = "1.7.0" ] || [ "${{ matrix.poetry-version }}" = "1.8.0" ]; then
# Known issue with virtualenv 20.31.x breaking these Poetry versions
pip install virtualenv==20.30.0
fi
- name: Install dependencies
run: |
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Install Supply-Chain Firewall
run: pip install .
- name: Test firewall Poetry integration
run: |
make test-poetry
make test-poetry-class
npm-integration:
name: npm-integration (${{ matrix.npm-version }})
runs-on: ubuntu-latest
strategy:
matrix:
include:
- node-version: "15.0.0"
npm-version: "7.0"
- node-version: "15.0.0"
npm-version: "7.1"
- node-version: "15.0.0"
npm-version: "7.2"
- node-version: "15.0.0"
npm-version: "7.3"
- node-version: "15.0.0"
npm-version: "7.4"
- node-version: "15.0.0"
npm-version: "7.5"
- node-version: "15.0.0"
npm-version: "7.6"
- node-version: "15.0.0"
npm-version: "7.7"
- node-version: "15.0.0"
npm-version: "7.8"
- node-version: "15.0.0"
npm-version: "7.9"
- node-version: "15.0.0"
npm-version: "7.10"
- node-version: "15.0.0"
npm-version: "7.11"
- node-version: "15.0.0"
npm-version: "7.12"
- node-version: "15.0.0"
npm-version: "7.13"
- node-version: "15.0.0"
npm-version: "7.14"
- node-version: "15.0.0"
npm-version: "7.15"
- node-version: "15.0.0"
npm-version: "7.16"
- node-version: "15.0.0"
npm-version: "7.17"
- node-version: "15.0.0"
npm-version: "7.18"
- node-version: "15.0.0"
npm-version: "7.19"
- node-version: "15.0.0"
npm-version: "7.20"
- node-version: "15.0.0"
npm-version: "7.21"
- node-version: "15.0.0"
npm-version: "7.22"
- node-version: "15.0.0"
npm-version: "7.23"
- node-version: "15.0.0"
npm-version: "7.24"
- node-version: "16.0.0"
npm-version: "8.0"
- node-version: "16.0.0"
npm-version: "8.1"
- node-version: "16.0.0"
npm-version: "8.2"
- node-version: "16.0.0"
npm-version: "8.3"
- node-version: "16.0.0"
npm-version: "8.4"
- node-version: "16.0.0"
npm-version: "8.5"
- node-version: "16.0.0"
npm-version: "8.6"
- node-version: "16.0.0"
npm-version: "8.7"
- node-version: "16.0.0"
npm-version: "8.8"
- node-version: "16.0.0"
npm-version: "8.9"
- node-version: "16.0.0"
npm-version: "8.10"
- node-version: "16.0.0"
npm-version: "8.11"
- node-version: "16.0.0"
npm-version: "8.12"
- node-version: "16.0.0"
npm-version: "8.13"
- node-version: "16.0.0"
npm-version: "8.14"
- node-version: "16.0.0"
npm-version: "8.15"
- node-version: "16.0.0"
npm-version: "8.16"
- node-version: "16.0.0"
npm-version: "8.17"
- node-version: "16.0.0"
npm-version: "8.18"
- node-version: "16.0.0"
npm-version: "8.19"
- node-version: "19.0.0"
npm-version: "9.0"
- node-version: "19.0.0"
npm-version: "9.1"
- node-version: "19.0.0"
npm-version: "9.2"
- node-version: "19.0.0"
npm-version: "9.3"
- node-version: "19.0.0"
npm-version: "9.4"
- node-version: "19.0.0"
npm-version: "9.5"
- node-version: "19.0.0"
npm-version: "9.6"
- node-version: "19.0.0"
npm-version: "9.7"
- node-version: "19.0.0"
npm-version: "9.8"
- node-version: "19.0.0"
npm-version: "9.9"
- node-version: "22.0.0"
npm-version: "10.0"
- node-version: "22.0.0"
npm-version: "10.1"
- node-version: "22.0.0"
npm-version: "10.2"
- node-version: "22.0.0"
npm-version: "10.3"
- node-version: "22.0.0"
npm-version: "10.4"
- node-version: "22.0.0"
npm-version: "10.5"
- node-version: "22.0.0"
npm-version: "10.6"
- node-version: "22.0.0"
npm-version: "10.7"
- node-version: "22.0.0"
npm-version: "10.8"
- node-version: "22.0.0"
npm-version: "10.9"
- node-version: "22.9.0"
npm-version: "11.0"
- node-version: "22.9.0"
npm-version: "11.1"
- node-version: "22.9.0"
npm-version: "11.2"
- node-version: "22.9.0"
npm-version: "11.3"
- node-version: "22.9.0"
npm-version: "11.4"
- node-version: "22.9.0"
npm-version: "11.5"
- node-version: "22.9.0"
npm-version: "11.6"
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Install Supply-Chain Firewall
run: pip install .
- name: Install Node.js v${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Test firewall npm v${{ matrix.npm-version }} integration
run: |
if [ "${{ matrix.node-version }}" = "15.0.0" ]; then
# Known issue on npm v7.x: need to first install this manually
npm install -g agentkeepalive
fi
npm install -g npm@${{ matrix.npm-version }}
make test-npm
make test-npm-class
verifiers:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Install Supply-Chain Firewall
run: pip install .
- name: Test firewall installation target verifiers
run: make test-verifiers