Module: StubRequests
- Extended by:
- StubRequests, UriFor
- Includes:
- API, UriFor
- Included in:
- StubRequests
- Defined in:
- lib/stub_requests/api.rb,
lib/stub_requests/dsl.rb,
lib/stub_requests/uri.rb,
lib/stub_requests/service.rb,
lib/stub_requests/version.rb,
lib/stub_requests/callback.rb,
lib/stub_requests/endpoint.rb,
lib/stub_requests/exceptions.rb,
lib/stub_requests/uri/scheme.rb,
lib/stub_requests/uri/suffix.rb,
lib/stub_requests/uri/builder.rb,
lib/stub_requests/utils/fuzzy.rb,
lib/stub_requests/request_stub.rb,
lib/stub_requests/configuration.rb,
lib/stub_requests/stub_registry.rb,
lib/stub_requests/stub_requests.rb,
lib/stub_requests/uri/validator.rb,
lib/stub_requests/webmock/builder.rb,
lib/stub_requests/service_registry.rb,
lib/stub_requests/callback_registry.rb,
lib/stub_requests/concerns/property.rb,
lib/stub_requests/dsl/define_method.rb,
lib/stub_requests/endpoint_registry.rb,
lib/stub_requests/dsl/method_definition.rb,
lib/stub_requests/concerns/register_verb.rb,
lib/stub_requests/concerns/property/validator.rb,
lib/stub_requests/concerns/argument_validation.rb,
lib/stub_requests/webmock/stub_registry_extension.rb
Overview
Abstraction over WebMock to reduce duplication
Defined Under Namespace
Modules: API, Concerns, URI, Utils, WebMock Classes: Callback, CallbackRegistry, Configuration, DSL, Endpoint, EndpointNotFound, EndpointRegistry, Error, InvalidArgumentType, InvalidCallback, InvalidUri, PropertyDefined, RequestStub, Service, ServiceNotFound, ServiceRegistry, StubRegistry, UriSegmentMismatch
Constant Summary collapse
- VERSION =
Returns a version string
"0.1.11"
Instance Method Summary collapse
-
#config ⇒ Configuration
Contains gem configuration.
-
#configure {|config| ... } ⇒ Configuration
Allows the gem to be configured.
- #logger ⇒ Object
- #logger=(obj) ⇒ Object
-
#version ⇒ String
The current version of the gem.
Methods included from API
#__stub_endpoint, #define_stubs, included, #print_stubs, #register_callback, #register_service, #stub_endpoint, #unregister_callback
Instance Method Details
#config ⇒ Configuration
Contains gem configuration
44 45 46 |
# File 'lib/stub_requests/stub_requests.rb', line 44 def config @config ||= Configuration.new end |
#configure {|config| ... } ⇒ Configuration
Allows the gem to be configured
33 34 35 36 |
# File 'lib/stub_requests/stub_requests.rb', line 33 def configure yield(config) if block_given? config end |
#logger ⇒ Object
48 49 50 |
# File 'lib/stub_requests/stub_requests.rb', line 48 def logger config.logger end |
#logger=(obj) ⇒ Object
52 53 54 |
# File 'lib/stub_requests/stub_requests.rb', line 52 def logger=(obj) config.logger = obj end |