feat: add build & release CLI commands #2
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Tests | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
unit: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.9", "3.10", "3.11"] | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: ./.github/actions/install | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Run unit tests | |
run: | | |
secator test unit | |
- name: Run coverage report | |
run: | | |
secator test coverage | |
lint: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.9", "3.10", "3.11"] | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: ./.github/actions/install | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Run lint tests | |
run: | | |
secator test lint | |
integration: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.11"] | |
test_type: ['tasks'] | |
# test_type: ['tasks', 'workflows', 'scans'] | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: ./.github/actions/install | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Setup docker compose | |
uses: KengoTODA/actions-setup-docker-compose@v1 | |
with: | |
version: '1.29.2' | |
- name: Install dependencies | |
run: | | |
secator install langs go | |
secator install langs ruby | |
secator install tools | |
- name: Add GOBIN to PATH | |
run: echo "${HOME}/.local/bin" >> $GITHUB_PATH | |
- name: Add GOPATH to PATH | |
run: echo "${HOME}/go/bin" >> $GITHUB_PATH | |
- name: Run integration tests (${{ matrix.test_type }}) | |
run: | | |
secator test integration --test tests.integration.test_${{ matrix.test_type }} |