mirror of
https://gitea.invidious.io/iv-org/shard-spectator.git
synced 2024-08-15 00:53:35 +00:00
Add empty matcher to DSL
This commit is contained in:
parent
ed3f524f8d
commit
30582f9a89
1 changed files with 10 additions and 0 deletions
|
@ -273,5 +273,15 @@ module Spectator::DSL
|
||||||
macro be_nil
|
macro be_nil
|
||||||
::Spectator::Matchers::NilMatcher.new
|
::Spectator::Matchers::NilMatcher.new
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Indicates that some collection should be empty.
|
||||||
|
#
|
||||||
|
# Example:
|
||||||
|
# ```
|
||||||
|
# expect([]).to be_empty
|
||||||
|
# ```
|
||||||
|
macro be_empty
|
||||||
|
::Spectator::Matchers::EmptyMatcher.new
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue