Skip to content

Commit 79a7f65

Browse files
committed
Split unit-tests on its own for performance
Signed-off-by: jose.vazquez <[email protected]>
1 parent 15aaed0 commit 79a7f65

File tree

2 files changed

+23
-3
lines changed

2 files changed

+23
-3
lines changed

.github/workflows/ci.yml

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ on:
55

66
jobs:
77
unit-test:
8-
name: AKO CI tests
8+
name: AKO unit-tests
99
runs-on: ubuntu-latest
1010
steps:
1111
- uses: actions/checkout@v5
@@ -18,7 +18,7 @@ jobs:
1818
enable-cache: 'true'
1919

2020
- name: Run testing
21-
run: devbox run -- 'GO_TEST_FLAGS="-coverprofile=coverage.out" make -j6 ci'
21+
run: devbox run -- 'GO_TEST_FLAGS="-coverprofile=coverage.out" make unit-test'
2222

2323
- name: Upload coverage to Codecov
2424
uses: codecov/codecov-action@v5
@@ -28,3 +28,19 @@ jobs:
2828
token: ${{ secrets.CODECOV_TOKEN }}
2929
files: coverage.out
3030
verbose: true
31+
32+
lint:
33+
name: AKO linting
34+
runs-on: ubuntu-latest
35+
steps:
36+
- uses: actions/checkout@v5
37+
with:
38+
ref: ${{github.event.pull_request.head.sha}}
39+
40+
- name: Install devbox
41+
uses: jetify-com/[email protected]
42+
with:
43+
enable-cache: 'true'
44+
45+
- name: Run all linters
46+
run: devbox run -- 'make -j3 all-lints'

Makefile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -681,6 +681,10 @@ shellcheck:
681681
fd --type f --extension sh --extension bash --extension ksh . | \
682682
xargs shellcheck --color=always $(SHELLCHECK_OPTIONS)
683683

684+
.PHONY: all-lints
685+
all-lints: fmt lint validate-manifests validate-api-docs check-licenses addlicense-check shellcheck vulncheck
686+
@echo "✅ CI ALL linting checks PASSED"
687+
684688
.PHONY: ci
685-
ci: fmt validate-manifests validate-api-docs check-licenses addlicense-check unit-test lint shellcheck vulncheck
689+
ci: unit-test all-lints
686690
@echo "✅ CI PASSED all checks"

0 commit comments

Comments
 (0)