Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup some e2e test configurations #14389

Merged
merged 1 commit into from
Aug 26, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 6 additions & 16 deletions tests/e2e/ctl_v3_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,12 +121,11 @@ func dialWithSchemeTest(cx ctlCtx) {
}

type ctlCtx struct {
t *testing.T
apiPrefix string
cfg e2e.EtcdProcessClusterConfig
quotaBackendBytes int64
corruptFunc func(string) error
noStrictReconfig bool
t *testing.T
apiPrefix string
cfg e2e.EtcdProcessClusterConfig
corruptFunc func(string) error
noStrictReconfig bool

epc *e2e.EtcdProcessCluster

Expand All @@ -143,9 +142,6 @@ type ctlCtx struct {

initialCorruptCheck bool

// for compaction
compactPhysical bool

// dir that was used during the test
dataDir string
}
Expand All @@ -156,6 +152,7 @@ func (cx *ctlCtx) applyOpts(opts []ctlOption) {
for _, opt := range opts {
opt(cx)
}

cx.initialCorruptCheck = true
}

Expand All @@ -179,10 +176,6 @@ func withInteractive() ctlOption {
return func(cx *ctlCtx) { cx.interactive = true }
}

func withQuota(b int64) ctlOption {
return func(cx *ctlCtx) { cx.quotaBackendBytes = b }
}

func withInitialCorruptCheck() ctlOption {
return func(cx *ctlCtx) { cx.initialCorruptCheck = true }
}
Expand Down Expand Up @@ -232,9 +225,6 @@ func testCtlWithOffline(t *testing.T, testFunc func(ctlCtx), testOfflineFunc fun
if !ret.quorum {
ret.cfg = *e2e.ConfigStandalone(ret.cfg)
}
if ret.quotaBackendBytes > 0 {
ret.cfg.QuotaBackendBytes = ret.quotaBackendBytes
}
ret.cfg.NoStrictReconfig = ret.noStrictReconfig
if ret.initialCorruptCheck {
ret.cfg.InitialCorruptCheck = ret.initialCorruptCheck
Expand Down