2019-07-25 01:27:42 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2012-08-29 01:49:26 -04:00
|
|
|
RSpec::Matchers.define :include_module do |expected|
|
|
|
|
match do
|
|
|
|
described_class.included_modules.include?(expected)
|
|
|
|
end
|
|
|
|
|
2015-03-27 22:49:57 -04:00
|
|
|
description do
|
2015-05-23 17:32:39 -04:00
|
|
|
"includes the #{expected} module"
|
2015-03-27 22:49:57 -04:00
|
|
|
end
|
|
|
|
|
|
|
|
failure_message do
|
2012-08-29 01:49:26 -04:00
|
|
|
"expected #{described_class} to include the #{expected} module"
|
|
|
|
end
|
|
|
|
end
|