Skip to content

Commit 222f5bd

Browse files
Merge pull request #390 from fmount/topotests
Improve topology tests
2 parents 8a47ecc + 6022341 commit 222f5bd

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

tests/functional/dnsmasq_controller_test.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -603,7 +603,8 @@ var _ = Describe("DNSMasq controller", func() {
603603
g.Expect(finalizers).To(ContainElement(
604604
fmt.Sprintf("openstack.org/dnsmasq-%s", dnsMasqName.Name)))
605605
}, timeout, interval).Should(Succeed())
606-
606+
})
607+
It("checks the previous topology has no reference anymore", func() {
607608
Eventually(func(g Gomega) {
608609
// Verify the previous referenced topology has no finalizers
609610
tp := GetTopology(types.NamespacedName{

tests/functional/memcached_controller_test.go

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,16 @@ var _ = Describe("Memcached Controller", func() {
195195
g.Expect(finalizers).To(ContainElement(
196196
fmt.Sprintf("openstack.org/memcached-%s", memcachedName.Name)))
197197
}, timeout, interval).Should(Succeed())
198-
198+
})
199+
It("checks the memcached topology Condition", func() {
200+
th.ExpectCondition(
201+
memcachedName,
202+
ConditionGetterFunc(MemcachedConditionGetter),
203+
condition.TopologyReadyCondition,
204+
corev1.ConditionTrue,
205+
)
206+
})
207+
It("checks the previous topology has no reference anymore", func() {
199208
Eventually(func(g Gomega) {
200209
// Verify the previous referenced topology has no finalizers
201210
tp := GetTopology(types.NamespacedName{

0 commit comments

Comments
 (0)