Skip to content

Commit

Permalink
logictest,application_api: skip even more tests under race
Browse files Browse the repository at this point in the history
These are prone to OOM'ing.

Epic: CRDB-8308
Release note: None
  • Loading branch information
rickystewart committed Dec 14, 2023
1 parent da553e3 commit 75c91c2
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 1 deletion.
3 changes: 3 additions & 0 deletions pkg/ccl/logictestccl/tests/3node-tenant/generated_test.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions pkg/cmd/generate-logictest/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ type testFileTemplateConfig struct {
Ccl bool
ForceProductionValues bool
IsMultiRegion bool
Is3NodeTenant bool
Package, TestRuleName, RelDir string
ConfigIdx int
TestCount int
Expand Down Expand Up @@ -176,6 +177,7 @@ func (t *testdir) dump() error {
tplCfg.TestCount = testCount
tplCfg.CockroachGoTestserverTest = cfg.UseCockroachGoTestserver
tplCfg.IsMultiRegion = strings.Contains(cfg.Name, "multiregion")
tplCfg.Is3NodeTenant = strings.HasSuffix(cfg.Name, "3node-tenant")
// The NumCPU calculation is a guess pulled out of thin air to
// allocate the tests which use 3-node clusters 2 vCPUs, and
// the ones which use more a bit more.
Expand Down
5 changes: 4 additions & 1 deletion pkg/cmd/generate-logictest/templates.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,10 @@ const templateText = `
{{- define "runLogicTest" }}
{{- if .LogicTest -}}
func runLogicTest(t *testing.T, file string) {
skip.UnderDeadlock(t, "times out and/or hangs")
{{ if .Is3NodeTenant }}if file == "fk" || file == "alter_primary_key" {
skip.UnderRace(t, "times out and/or OOM's")
}
{{ end }}skip.UnderDeadlock(t, "times out and/or hangs")
logictest.RunLogicTest(t, logictest.TestServerArgs{}, configIdx, filepath.Join(logicTestDir, file))
}
{{ end }}
Expand Down
2 changes: 2 additions & 0 deletions pkg/server/application_api/sql_stats_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ func TestStatusAPICombinedTransactions(t *testing.T) {
defer leaktest.AfterTest(t)()
defer log.Scope(t).Close(t)

skip.UnderRace(t, "probable OOM")

// Increase the timeout for the http client if under stress.
additionalTimeout := 0 * time.Second
if skip.Stress() {
Expand Down

0 comments on commit 75c91c2

Please sign in to comment.