Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/publish-controller-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,20 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v7

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
uses: docker/setup-buildx-action@v4

- name: Log in to Quay.io
uses: docker/login-action@v3
uses: docker/login-action@v4
with:
registry: quay.io
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_ROBOT_TOKEN }}

- name: Build and push management-controller
uses: docker/build-push-action@v6
uses: docker/build-push-action@v7
with:
context: .
file: Containerfile
Expand All @@ -47,7 +47,7 @@ jobs:
cache-to: type=gha,mode=max,scope=management-controller

- name: Build and push site-controller
uses: docker/build-push-action@v6
uses: docker/build-push-action@v7
with:
context: .
file: Containerfile
Expand Down
108 changes: 108 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
name: Test Suite

on:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this new action be constrained to run on the upstream repo only?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's not a requirement like the image workflow since it doesn't rely on repo secrets, but it probably doesn't add much value to have it run on our forks and may just add noise when rebasing. I can add that constraint.

pull_request:
branches:
- main
push:
branches:
- main
workflow_dispatch:

permissions:
contents: read

concurrency:
group: test-suite-${{ github.ref }}
cancel-in-progress: true

jobs:
unit:
if: github.repository == 'skupperproject/vms'
name: Unit tests
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v7

- name: Install pnpm
uses: pnpm/action-setup@v6
with:
version: 11.18.0

- name: Set up Node.js
uses: actions/setup-node@v7
with:
node-version: 24
cache: pnpm

- name: Install dependencies
run: pnpm install --frozen-lockfile

- name: Run unit tests
run: pnpm run test:unit --reporter=json --outputFile=unit-test-results.json

- name: Upload test results
if: always()
uses: actions/upload-artifact@v7
with:
name: unit-test-results
path: unit-test-results.json

integration:
if: github.repository == 'skupperproject/vms'
name: Integration tests
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@v7

- name: Install pnpm
uses: pnpm/action-setup@v6
with:
version: 11.18.0

- name: Set up Node.js
uses: actions/setup-node@v7
with:
node-version: 24
cache: pnpm

- name: Install Kind
uses: helm/kind-action@v1
with:
install_only: true

- name: Install Helm
uses: azure/setup-helm@v5

- name: Install helmfile
run: |
HELMFILE_VERSION="v1.4.2"
curl -fsSL "https://github.com/helmfile/helmfile/releases/download/${HELMFILE_VERSION}/helmfile_${HELMFILE_VERSION#v}_linux_amd64.tar.gz" \
| sudo tar xz -C /usr/local/bin helmfile
helmfile version

- name: Install helm-diff plugin
run: helm plugin install --verify=false https://github.com/databus23/helm-diff

- name: Install dependencies
run: pnpm install --frozen-lockfile

- name: Bring up Kind cluster
run: pnpm run cluster:up

- name: Run integration tests
run: pnpm run test:integration --reporter=json --outputFile=integration-test-results.json

- name: Upload test results
if: always()
uses: actions/upload-artifact@v7
with:
name: integration-test-results
path: integration-test-results.json

- name: Tear down Kind cluster
if: always()
run: pnpm run cluster:down