Class: ConvenientService::RSpec::Helpers::Classes::StubService
- Inherits:
-
Support::Command
- Object
- Support::Command
- ConvenientService::RSpec::Helpers::Classes::StubService
- Defined in:
- lib/convenient_service/rspec/helpers/classes/stub_service.rb,
lib/convenient_service/rspec/helpers/classes/stub_service/constants.rb,
lib/convenient_service/rspec/helpers/classes/stub_service/entities/result_spec.rb,
lib/convenient_service/rspec/helpers/classes/stub_service/entities/stubbed_service.rb
Defined Under Namespace
Instance Attribute Summary collapse
-
#service_class ⇒ Object
readonly
Returns the value of attribute service_class.
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(service_class) ⇒ StubService
constructor
A new instance of StubService.
Methods inherited from Support::Command
Constructor Details
#initialize(service_class) ⇒ StubService
Returns a new instance of StubService.
16 17 18 |
# File 'lib/convenient_service/rspec/helpers/classes/stub_service.rb', line 16 def initialize(service_class) @service_class = service_class end |
Instance Attribute Details
#service_class ⇒ Object (readonly)
Returns the value of attribute service_class.
14 15 16 |
# File 'lib/convenient_service/rspec/helpers/classes/stub_service.rb', line 14 def service_class @service_class end |
Instance Method Details
#call ⇒ Object
20 21 22 |
# File 'lib/convenient_service/rspec/helpers/classes/stub_service.rb', line 20 def call Entities::StubbedService.new(service_class: @service_class) end |