From 295dfd34aab6e63050d5f1ba8e6ffc9505dd28a3 Mon Sep 17 00:00:00 2001 From: CrazyBolillo Date: Wed, 14 Feb 2024 22:31:21 -0600 Subject: build: run example tests during CI workflow Tests for examples exist, however they were not being run as part of the CI. This commit fixes it by adding a new step in the test workflow which runs said tests. Related to #912. --- .github/workflows/test.yml | 5 +++++ 1 file changed, 5 insertions(+) (limited to '.github') diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f94d3e7..2218208 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -34,3 +34,8 @@ jobs: - name: Test run: make test-coverage + + - name: Examples + env: + EXAMPLES_DIR: _examples + run: go test -test.v -test.run='^TestBuildExamples$' -- cgit From c751b7bca746c15c9da847bf1e8dec56c520c24e Mon Sep 17 00:00:00 2001 From: Paulo Gomes Date: Fri, 26 Jul 2024 20:01:48 +0100 Subject: build: Fix syntax to test examples on Windows Signed-off-by: Paulo Gomes --- .github/workflows/test.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to '.github') diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2218208..2753b73 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -35,7 +35,5 @@ jobs: - name: Test run: make test-coverage - - name: Examples - env: - EXAMPLES_DIR: _examples - run: go test -test.v -test.run='^TestBuildExamples$' + - name: Test Examples + run: go test -timeout 30s -v -run '^TestExamples$' github.com/go-git/go-git/v5/_examples --examples -- cgit