I would like to know the equivalent of:
event.should be_live
in Minitest? The method I am testing is:
event.live?
At the moment I am using:
conf.live?.must_equal true
But it looks to me quite contrived.
Newer versions of minitest allow testing predicates in assert_operator
. The expectation for that in the spec DSL is must_be
. So your code can look like:
event.must_be :live?