Sha256: 7be4df7eef40a8fa719603da96323afbde9323796388083671b8489cb475f58a
Contents?: true
Size: 473 Bytes
Versions: 24
Compression:
Stored size: 473 Bytes
Contents
# :nocov: RSpec::Matchers.define :permit do |action| match do |policy| policy.public_send("#{action}?") end failure_message do |policy| <<~STRING #{policy.class} does not permit #{action} on #{policy.record} for #{policy.user.inspect}. STRING end failure_message_when_negated do |policy| <<~STRING #{policy.class} does not forbid #{action} on #{policy.record} for #{policy.user.inspect}. STRING end end # :nocov:
Version data entries
24 entries across 24 versions & 1 rubygems