Skip to content

Helm

Helm #3600

name: PR Tests - Enclave
on:
workflow_call:
pull_request:
branches:
- dev
- main
- "0.8"
workflow_dispatch:
inputs:
none:
description: "Run Tests Manually"
required: false
concurrency:
group: enclave-${{ github.event_name == 'pull_request' && format('{0}-{1}', github.workflow, github.event.pull_request.number) || github.workflow_ref }}
cancel-in-progress: true
jobs:
pr-tests-enclave-oblv:
strategy:
max-parallel: 4
matrix:
os: [ubuntu-latest]
python-version: ["3.11"]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
# free 10GB of space
- name: Remove unnecessary files
if: matrix.os == 'ubuntu-latest'
run: |
sudo rm -rf /usr/share/dotnet
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
docker image prune --all --force
docker builder prune --all --force
docker system prune --all --force
- name: Check for file changes
uses: dorny/paths-filter@v2
id: changes
with:
base: ${{ github.ref }}
token: ${{ github.token }}
filters: .github/file-filters.yml
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
if: steps.changes.outputs.syft == 'true'
with:
python-version: ${{ matrix.python-version }}
- name: Upgrade pip
if: steps.changes.outputs.syft == 'true'
run: |
python -m pip install --upgrade --user pip
- name: Get pip cache dir
id: pip-cache
if: steps.changes.outputs.syft == 'true'
shell: bash
run: |
echo "dir=$(pip cache dir)" >> $GITHUB_OUTPUT
- name: pip cache
uses: actions/cache@v3
if: steps.changes.outputs.syft == 'true'
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-pip-py${{ matrix.python-version }}-${{ hashFiles('setup.cfg') }}
restore-keys: |
${{ runner.os }}-pip-py${{ matrix.python-version }}-
- name: Install Dependencies
if: steps.changes.outputs.syft == 'true'
run: |
pip install --upgrade tox packaging wheel --default-timeout=60
# Temporarily disabled oblv tests
# - name: Run Enclave tests
# if: steps.changes.outputs.syft == 'true'
# run: |
# tox -e stack.test.integration.enclave.oblv