Skip to content

chore(codecov): configure components #477

chore(codecov): configure components

chore(codecov): configure components #477

Workflow file for this run

name: test
on:
push:
branches:
- main
paths-ignore:
- "README.md"
pull_request:
paths-ignore:
- "README.md"
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v4.2.2
- uses: actions/setup-go@v5.2.0
with:
go-version-file: "go.mod"
cache: true
- run: go mod download
- run: go build -v .
test:
runs-on: ubuntu-latest
timeout-minutes: 15
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v4.2.2
- uses: actions/setup-go@v5.2.0
with:
go-version-file: "go.mod"
cache: true
- run: go mod download
- run: go test -v -coverprofile=coverage.txt -covermode=atomic -coverpkg=./... ./...
timeout-minutes: 10
- uses: codecov/codecov-action@v5.1.2
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: test
contentful-management-go-test:
runs-on: ubuntu-latest
timeout-minutes: 15
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v4.2.2
- uses: actions/setup-go@v5.2.0
with:
go-version-file: "go.mod"
cache: true
- run: go mod download
- run: go test -v -coverprofile=coverage.txt -covermode=atomic ./internal/contentful-management-go/...
env:
CONTENTFUL_MANAGEMENT_ACCESS_TOKEN: ${{ secrets.CONTENTFUL_MANAGEMENT_ACCESS_TOKEN }}
timeout-minutes: 10
- uses: codecov/codecov-action@v5.1.2
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: contentful-management-go
testacc:
runs-on: ubuntu-latest
timeout-minutes: 15
strategy:
fail-fast: false
matrix:
terraform:
- "1.8.*"
- "1.9.*"
concurrency:
group: testacc
steps:
- uses: actions/checkout@v4.2.2
- uses: actions/setup-go@v5.2.0
with:
go-version-file: "go.mod"
cache: true
- uses: hashicorp/setup-terraform@v3.1.2
with:
terraform_version: ${{ matrix.terraform }}
terraform_wrapper: false
- run: go mod download
- run: go test -v -coverprofile=coverage.txt -covermode=atomic -coverpkg=./... ./internal/provider/
env:
TF_ACC: "1"
CONTENTFUL_MANAGEMENT_ACCESS_TOKEN: ${{ secrets.CONTENTFUL_MANAGEMENT_ACCESS_TOKEN }}
timeout-minutes: 10
- uses: codecov/codecov-action@v5.1.2
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: testacc-${{ matrix.terraform }}