Skip to content

ci: add static validation checks for sample assets #1

ci: add static validation checks for sample assets

ci: add static validation checks for sample assets #1

Workflow file for this run

name: Static Checks
# Runs fast, offline static validation of the sample assets (OpenJD templates,
# host configuration scripts, CloudFormation templates, and Conda recipes) so
# that problems -- for example a host configuration script that exceeds the
# service's size limit -- are caught in CI instead of by a customer.
on:
push:
branches: ["mainline"]
pull_request:
branches: ["mainline"]
permissions:
contents: read
concurrency:
group: static-checks-${{ github.ref }}
cancel-in-progress: true
jobs:
static-checks:
name: Static validation
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
# Cache pip downloads keyed on the test requirements file so the
# openjd-cli / cfn-lint install is restored from cache on unchanged runs.
cache: pip
cache-dependency-path: tests/requirements.txt
- name: Install test dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r tests/requirements.txt
- name: Run static checks
working-directory: tests
run: python -m pytest -v