Merge pull request #142 from karimra/session-id #458
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: Commit | |
on: | |
- push | |
- pull_request | |
- workflow_dispatch | |
jobs: | |
unit-test: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
max-parallel: 8 | |
matrix: | |
os: | |
- ubuntu-latest | |
- macos-latest | |
go-version: | |
- "1.16" | |
- "1.17" | |
- "1.18" | |
- "1.19" | |
steps: | |
- name: checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: set up go ${{ matrix.go-version }} | |
uses: actions/setup-go@v4 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: lint | |
uses: golangci/golangci-lint-action@v3 | |
with: | |
version: v1.52 | |
args: --timeout 5m | |
- name: install gotestsum | |
run: go install gotest.tools/gotestsum@latest | |
- name: tests | |
run: make test-race | |
functional-test: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- ubuntu-latest | |
go-version: | |
- "1.19" | |
runtime: | |
- "docker" | |
needs: | |
- unit-test | |
steps: | |
- name: checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: set up go ${{ matrix.go-version }} | |
uses: actions/setup-go@v4 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: install gotestsum | |
run: go install gotest.tools/gotestsum@latest | |
# pull the srl image before installing clab so that clab has no need to pull it when starting | |
# -- make sure this is the same image version that is in the clab ci topo! | |
- name: pull srlinux image | |
run: docker pull ghcr.io/nokia/srlinux:21.11.3 | |
- name: install clab | |
run: bash -c "$(curl -sL https://get.containerlab.dev)" -- -v 0.36.1 | |
- name: start clab ci topo | |
run: make deploy-clab-ci | |
- name: tests | |
run: make test-ci |