From 5e6e1015556c46b8a7509301f9a6a8fa83dc8686 Mon Sep 17 00:00:00 2001 From: Tanishq Dubey Date: Fri, 16 May 2025 20:06:43 -0400 Subject: [PATCH] Switch to gitea actions --- .gitea/workflows/test_integration.yml | 28 +++++++++++++++++++ .../workflows/test_unit.yml | 13 +++++---- 2 files changed, 35 insertions(+), 6 deletions(-) create mode 100644 .gitea/workflows/test_integration.yml rename .github/workflows/test.yml => .gitea/workflows/test_unit.yml (58%) diff --git a/.gitea/workflows/test_integration.yml b/.gitea/workflows/test_integration.yml new file mode 100644 index 0000000..5368031 --- /dev/null +++ b/.gitea/workflows/test_integration.yml @@ -0,0 +1,28 @@ +name: Integration Tests + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +jobs: + integration-tests: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - name: Set up Go + uses: actions/setup-go@v4 + with: + go-version: '1.24' + + - name: Install dependencies + run: go mod download + + - name: Run integration tests + run: go test -count=1 -run Integration ./... -v -coverprofile=coverage.out + + - name: Print coverage report + run: go tool cover -func=coverage.out + continue-on-error: true \ No newline at end of file diff --git a/.github/workflows/test.yml b/.gitea/workflows/test_unit.yml similarity index 58% rename from .github/workflows/test.yml rename to .gitea/workflows/test_unit.yml index 9c91ea3..7a048f1 100644 --- a/.github/workflows/test.yml +++ b/.gitea/workflows/test_unit.yml @@ -1,4 +1,4 @@ -name: Test +name: Unit Tests on: push: @@ -7,7 +7,7 @@ on: branches: [ main ] jobs: - test: + unit-tests: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 @@ -15,13 +15,14 @@ jobs: - name: Set up Go uses: actions/setup-go@v4 with: - go-version: '1.21' + go-version: '1.24' - name: Install dependencies run: go mod download - name: Run unit tests - run: go test -v ./internal/... -short + run: go test -v ./... -coverprofile=coverage.out - - name: Run integration tests - run: go test -v ./internal/... -run Integration + - name: Print coverage report + run: go tool cover -func=coverage.out + continue-on-error: true \ No newline at end of file