Skip to content

Commit da9d1eb

Browse files
Merge pull request #339 from btoll/OSD-29465
Combine the create and delete tests into one to avoid dependencies between tests
2 parents 78779bc + ba4843f commit da9d1eb

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

test/e2e/splunk_forwarder_operator_tests.go

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -118,15 +118,11 @@ var _ = ginkgo.Describe("Splunk Forwarder Operator", ginkgo.Ordered, func() {
118118

119119
})
120120

121-
sf := makeMinimalSplunkforwarder(testsplunkforwarder)
122-
123-
ginkgo.It("admin should be able to create SplunkForwarders CR", func(ctx context.Context) {
121+
ginkgo.It("admin should be able to create and delete SplunkForwarders CR", func(ctx context.Context) {
122+
sf := makeMinimalSplunkforwarder(testsplunkforwarder)
124123
err := k8s.WithNamespace(operatorNamespace).Create(ctx, &sf)
125124
Expect(err).NotTo(HaveOccurred())
126-
})
127-
128-
ginkgo.It("admin should be able to delete SplunkForwarders CR", func(ctx context.Context) {
129-
err := k8s.Delete(ctx, &sf)
125+
err = k8s.WithNamespace(operatorNamespace).Delete(ctx, &sf)
130126
Expect(err).NotTo(HaveOccurred())
131127
})
132128

0 commit comments

Comments
 (0)