-
Notifications
You must be signed in to change notification settings - Fork 98
67 lines (61 loc) · 1.69 KB
/
bats.yml
File metadata and controls
67 lines (61 loc) · 1.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
name: bats
on:
push:
branches:
- 'main'
tags:
- 'v*'
pull_request:
branches: [ main ]
workflow_dispatch:
env:
GO_VERSION: "1.23"
K8S_VERSION: "v1.32.0"
KIND_VERSION: "v0.27.0"
jobs:
bats_tests:
runs-on: ubuntu-22.04
name: Bats e2e tests
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Setup Bats and bats libs
id: setup-bats
uses: bats-core/bats-action@3.0.0
- name: Bats tests
shell: bash
env:
BATS_LIB_PATH: ${{ steps.setup-bats.outputs.lib-path }}
TERM: xterm
run: bats -o _artifacts tests/
- name: Upload logs
if: always()
uses: actions/upload-artifact@v4
with:
name: kind-logs-${{ env.JOB_NAME }}-${{ github.run_id }}
path: ./_artifacts
bats_mac_tests:
runs-on: macos-15
name: Bats e2e tests on Mac
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up environment (download dependencies)
run: |
brew install docker
brew install kind
brew install bats-core
- name: Setup tmate session
uses: mxschmitt/action-tmate@v3
- name: Bats tests
env:
TERM: linux # fix tput for tty issue work around
run: |
bash --version
bash -c "time bats -o _artifacts --trace --formatter tap tests/"
- name: Upload logs
if: always()
uses: actions/upload-artifact@v4
with:
name: kind-logs-${{ env.JOB_NAME }}-${{ github.run_id }}
path: ./_artifacts