Skip to content

Commit

Permalink
Update tests for RabbitMQ 4.0.x (rabbitmq/rabbitmq-server#12552)
Browse files Browse the repository at this point in the history
(cherry picked from commit a3d2b85)
  • Loading branch information
michaelklishin committed Nov 25, 2024
1 parent 3ba0e94 commit 53bad9c
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions rabbithole_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4170,7 +4170,10 @@ var _ = Describe("RabbitMQ HTTP API client", func() {
list, err := rmqc.ListGlobalParameters()
Ω(err).Should(BeNil())
Ω(list).To(SatisfyAll(
HaveLen(4), // cluster_name and internal_cluster_id are set by default by RabbitMQ
// RabbitMQ 4.0.x and later versions will have an
// extra global runtime parameter by default, see
// https://github.com/rabbitmq/rabbitmq-server/issues/12552
Or(HaveLen(5), HaveLen(4)),
ContainElements(
GlobalRuntimeParameter{
Name: "a-name",
Expand All @@ -4193,7 +4196,10 @@ var _ = Describe("RabbitMQ HTTP API client", func() {
Ω(err).Should(BeNil())

return len(xs)
}).Should(Equal(2))
// RabbitMQ 4.0.x and later versions will have an
// extra global runtime parameter by default, see
// https://github.com/rabbitmq/rabbitmq-server/issues/12552
}).Should(Or(Equal(3), Equal(2)))
})
})
})
Expand Down

0 comments on commit 53bad9c

Please sign in to comment.