Sha256: adef6eb213c0713f9e18dd35f275a845e104e9851f47e62411073247c10aa361
Contents?: true
Size: 479 Bytes
Versions: 11
Compression:
Stored size: 479 Bytes
Contents
module SimpleService class ValidatesExpectedKeys < Command expects :expected_keys, :provided_keys skip_validation true # prevent infinite loop def call arguments_not_included = expected_keys.to_a - provided_keys.to_a if arguments_not_included.any? error_msg = 'keys required by the organizer but not found in the context: ' + arguments_not_included.join(', ') raise ExpectedKeyError, error_msg end end end end
Version data entries
11 entries across 11 versions & 1 rubygems