mirror of
https://github.com/wagoodman/dive
synced 2026-03-14 22:35:50 +01:00
111 lines
2.5 KiB
YAML
111 lines
2.5 KiB
YAML
name: "Validations"
|
|
on:
|
|
workflow_dispatch:
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
|
|
jobs:
|
|
Static-Analysis:
|
|
name: "Static analysis"
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Bootstrap environment
|
|
uses: ./.github/actions/bootstrap
|
|
|
|
- name: Run static analysis
|
|
run: make static-analysis
|
|
|
|
Unit-Test:
|
|
name: "Unit tests"
|
|
strategy:
|
|
matrix:
|
|
platform:
|
|
- ubuntu-latest
|
|
runs-on: ${{ matrix.platform }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Bootstrap environment
|
|
uses: ./.github/actions/bootstrap
|
|
|
|
- name: Run unit tests
|
|
run: make unit
|
|
|
|
Build-Snapshot-Artifacts:
|
|
name: "Build snapshot artifacts"
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Bootstrap environment
|
|
uses: ./.github/actions/bootstrap
|
|
|
|
- name: Set up QEMU
|
|
uses: docker/setup-qemu-action@v3
|
|
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v3
|
|
|
|
- name: Build snapshot artifacts
|
|
run: make snapshot
|
|
|
|
- name: Upload snapshot artifacts
|
|
uses: actions/cache/save@v4
|
|
with:
|
|
path: snapshot
|
|
key: snapshot-build-${{ github.run_id }}
|
|
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: windows-artifacts
|
|
path: snapshot/superdive_windows_amd64_v1/superdive.exe
|
|
|
|
Acceptance-Linux:
|
|
name: "Acceptance tests (Linux)"
|
|
needs: [Build-Snapshot-Artifacts]
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@master
|
|
|
|
- name: Download snapshot build
|
|
uses: actions/cache/restore@v4
|
|
with:
|
|
path: snapshot
|
|
key: snapshot-build-${{ github.run_id }}
|
|
|
|
- name: Test linux run
|
|
run: make ci-test-linux-run
|
|
|
|
Acceptance-Mac:
|
|
name: "Acceptance tests (Mac)"
|
|
needs: [Build-Snapshot-Artifacts]
|
|
runs-on: macos-latest
|
|
steps:
|
|
- uses: actions/checkout@master
|
|
|
|
- name: Download snapshot build
|
|
uses: actions/cache/restore@v4
|
|
with:
|
|
path: snapshot
|
|
key: snapshot-build-${{ github.run_id }}
|
|
|
|
- name: Test darwin run
|
|
run: make ci-test-mac-run
|
|
|
|
Acceptance-Windows:
|
|
name: "Acceptance tests (Windows)"
|
|
needs: [Build-Snapshot-Artifacts]
|
|
runs-on: windows-latest
|
|
steps:
|
|
- uses: actions/checkout@master
|
|
|
|
- uses: actions/download-artifact@v4
|
|
with:
|
|
name: windows-artifacts
|
|
|
|
- name: Test windows run
|
|
run: make ci-test-windows-run
|