Files
growstuff/spec/custom_matchers.rb
Brenda Wallace 723ebff923 Spacing fixes
2016-11-26 12:13:17 +13:00

8 lines
178 B
Ruby

require 'rspec/expectations'
RSpec::Matchers.define :have_optional do |expected|
match do |actual|
actual.has_selector? "#{expected} + span", text: '(Optional)'
end
end