Sha256: 6bc683ba213c82506fd85ec9375f43bba9f53723720aa4bfcc2a7532030b3d8a
Contents?: true
Size: 505 Bytes
Versions: 4
Compression:
Stored size: 505 Bytes
Contents
require 'pact/provider/rspec' require 'rspec/mocks' class StubbedThing def self.stub_me end end class App def self.call env [200, {}, [StubbedThing.stub_me]] end end Pact.configure do | config | config.include RSpec::Mocks::ExampleMethods end Pact.provider_states_for 'Consumer' do provider_state 'something is stubbed' do set_up do allow(StubbedThing).to receive(:stub_me).and_return("stubbing works") end end end Pact.service_provider 'Provider' do app { App } end
Version data entries
4 entries across 4 versions & 1 rubygems