mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2025-01-05 15:18:43 +00:00
Run tests on main
branch (#2576)
We currently don't have coverage information on codecov, the tests must run for `main` pushes so we can publish them afterwards
This commit is contained in:
parent
1b98e58014
commit
55766ea693
1 changed files with 12 additions and 5 deletions
|
@ -17,7 +17,7 @@ variables:
|
||||||
- "go.*"
|
- "go.*"
|
||||||
# schema changes
|
# schema changes
|
||||||
- "pipeline/schema/**"
|
- "pipeline/schema/**"
|
||||||
event: [pull_request, tag, deployment]
|
event: [pull_request, tag]
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
vendor:
|
vendor:
|
||||||
|
@ -25,7 +25,8 @@ steps:
|
||||||
group: prepare
|
group: prepare
|
||||||
commands:
|
commands:
|
||||||
- go mod vendor
|
- go mod vendor
|
||||||
when: *when
|
when:
|
||||||
|
- path: *when_path
|
||||||
|
|
||||||
lint-pipeline:
|
lint-pipeline:
|
||||||
image: *golang_image
|
image: *golang_image
|
||||||
|
@ -64,9 +65,12 @@ steps:
|
||||||
lint-editorconfig:
|
lint-editorconfig:
|
||||||
image: mstruebing/editorconfig-checker:2.7.2
|
image: mstruebing/editorconfig-checker:2.7.2
|
||||||
group: test
|
group: test
|
||||||
|
when:
|
||||||
|
- event: [pull_request, tag]
|
||||||
|
|
||||||
lint-license-header:
|
lint-license-header:
|
||||||
image: *golang_image
|
image: *golang_image
|
||||||
|
group: test
|
||||||
commands:
|
commands:
|
||||||
- go install github.com/google/addlicense@latest
|
- go install github.com/google/addlicense@latest
|
||||||
- "addlicense -check -ignore \"vendor/**\" **/*.go"
|
- "addlicense -check -ignore \"vendor/**\" **/*.go"
|
||||||
|
@ -80,7 +84,8 @@ steps:
|
||||||
- make test-server
|
- make test-server
|
||||||
- make test-cli
|
- make test-cli
|
||||||
- make test-lib
|
- make test-lib
|
||||||
when: *when
|
when:
|
||||||
|
- path: *when_path
|
||||||
|
|
||||||
sqlite:
|
sqlite:
|
||||||
image: *golang_image
|
image: *golang_image
|
||||||
|
@ -89,7 +94,8 @@ steps:
|
||||||
- WOODPECKER_DATABASE_DRIVER=sqlite3
|
- WOODPECKER_DATABASE_DRIVER=sqlite3
|
||||||
commands:
|
commands:
|
||||||
- make test-server-datastore-coverage
|
- make test-server-datastore-coverage
|
||||||
when: *when
|
when:
|
||||||
|
- path: *when_path
|
||||||
|
|
||||||
postgres:
|
postgres:
|
||||||
image: *golang_image
|
image: *golang_image
|
||||||
|
@ -123,7 +129,8 @@ steps:
|
||||||
- datastore-coverage.out
|
- datastore-coverage.out
|
||||||
token:
|
token:
|
||||||
from_secret: codecov_token
|
from_secret: codecov_token
|
||||||
when: *when
|
when:
|
||||||
|
- path: *when_path
|
||||||
failure: ignore
|
failure: ignore
|
||||||
|
|
||||||
services:
|
services:
|
||||||
|
|
Loading…
Reference in a new issue