Skip to content

Commit

Permalink
schemachanger: force prod values in expensive test
Browse files Browse the repository at this point in the history
Release note: None
  • Loading branch information
rafiss committed Oct 29, 2024
1 parent ce067c6 commit b2c5ad3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions pkg/sql/schemachanger/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ go_test(
"//pkg/sql/schemachanger/scop",
"//pkg/sql/schemachanger/scplan",
"//pkg/sql/schemachanger/sctest", # keep
"//pkg/sql/sem/eval",
"//pkg/sql/sessiondatapb",
"//pkg/testutils",
"//pkg/testutils/serverutils",
Expand Down
6 changes: 6 additions & 0 deletions pkg/sql/schemachanger/dml_injection_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import (
"github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scexec"
"github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scop"
"github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scplan"
"github.com/cockroachdb/cockroach/pkg/sql/sem/eval"
"github.com/cockroachdb/cockroach/pkg/testutils/serverutils"
"github.com/cockroachdb/cockroach/pkg/testutils/skip"
"github.com/cockroachdb/cockroach/pkg/testutils/sqlutils"
Expand Down Expand Up @@ -457,6 +458,11 @@ func TestAlterTableDMLInjection(t *testing.T) {
testCluster := serverutils.StartCluster(t, 1, base.TestClusterArgs{
ServerArgs: base.TestServerArgs{
Knobs: base.TestingKnobs{
SQLEvalContext: &eval.TestingKnobs{
// We disable the randomization of some batch sizes because with
// some low values the test takes much longer.
ForceProductionValues: true,
},
SQLDeclarativeSchemaChanger: &scexec.TestingKnobs{
BeforeStage: func(p scplan.Plan, stageIdx int) error {
if !clusterCreated.Load() {
Expand Down

0 comments on commit b2c5ad3

Please sign in to comment.