Module: SimpleCrud::RSpec::Helpers::ControllerOptions

Included in:
SimpleCrud::RSpec::Helpers
Defined in:
lib/simple_crud/rspec/helpers/controller_options.rb

Overview

Definition-time introspection of the options each action was declared with via simple_crud_for (read from the controller's metadata).

Instance Method Summary collapse

Instance Method Details

#get_option(method, option) ⇒ Object



9
10
11
# File 'lib/simple_crud/rspec/helpers/controller_options.rb', line 9

def get_option(method, option)
  described_class.instance_variable_get(:@simple_crud_metadata)[method][option]
end