Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite797183

Browse files
committed
add pg race test to ci
1 parentcd9b4d1 commite797183

File tree

1 file changed

+47
-1
lines changed

1 file changed

+47
-1
lines changed

‎.github/workflows/ci.yaml‎

Lines changed: 47 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -538,6 +538,47 @@ jobs:
538538
with:
539539
api-key:${{ secrets.DATADOG_API_KEY }}
540540

541+
test-go-race-pg:
542+
runs-on:${{ github.repository_owner == 'coder' && 'depot-ubuntu-22.04-16' || 'ubuntu-latest' }}
543+
needs:changes
544+
if:needs.changes.outputs.go == 'true' || needs.changes.outputs.ci == 'true' || github.ref == 'refs/heads/main'
545+
timeout-minutes:25
546+
steps:
547+
-name:Harden Runner
548+
uses:step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7# v2.10.1
549+
with:
550+
egress-policy:audit
551+
552+
-name:Checkout
553+
uses:actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871# v4.2.1
554+
with:
555+
fetch-depth:1
556+
557+
-name:Setup Go
558+
uses:./.github/actions/setup-go
559+
560+
-name:Setup Terraform
561+
uses:./.github/actions/setup-tf
562+
563+
# We run race tests with reduced parallelism because they use more CPU and we were finding
564+
# instances where tests appear to hang for multiple seconds, resulting in flaky tests when
565+
# short timeouts are used.
566+
# c.f. discussion on https://github.com/coder/coder/pull/15106
567+
-name:Run Tests
568+
env:
569+
POSTGRES_VERSION:"16"
570+
run:|
571+
make test-postgres-docker
572+
DB=ci gotestsum --junitfile="gotests.xml" -- -race -parallel 4 -p 4 ./...
573+
574+
-name:Upload test stats to Datadog
575+
timeout-minutes:1
576+
continue-on-error:true
577+
uses:./.github/actions/upload-datadog
578+
if:always()
579+
with:
580+
api-key:${{ secrets.DATADOG_API_KEY }}
581+
541582
# Tailnet integration tests only run when the `tailnet` directory or `go.sum`
542583
# and `go.mod` are changed. These tests are to ensure we don't add regressions
543584
# to tailnet, either due to our code or due to updating dependencies.
@@ -815,6 +856,7 @@ jobs:
815856
-test-go
816857
-test-go-pg
817858
-test-go-race
859+
-test-go-race-pg
818860
-test-js
819861
-test-e2e
820862
-offlinedocs
@@ -862,7 +904,11 @@ jobs:
862904
if sum(results.values()) == 0:
863905
print("test-go-pg on windows-2022 failed, but we are temporarily skipping it until it's fixed")
864906
continue
865-
907+
908+
if job_name == "test-go-race-pg" and result == "failure":
909+
print("test-go-race-pg failed, but we are temporarily skipping it until it's fixed")
910+
continue
911+
866912
if result in ["failure", "cancelled"]:
867913
failed =True
868914
break

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp