Sha256: e8db9520e92fd0974a73baa55ead61b773fc8b3bbf33edf2b225661d791fc7ad

Contents?: true

Size: 602 Bytes

Versions: 11

Compression:

Stored size: 602 Bytes

Contents

class Evil::Client
  #
  # Collection of RSpec-related definitions
  #
  module RSpec
    require_relative "rspec/evil_client_schema_matching"
    require_relative "rspec/base_stub"
    require_relative "rspec/allow_stub"
    require_relative "rspec/expect_stub"

    def stub_client_operation(klass = Evil::Client, name = nil)
      AllowStub.new(klass, name)
    end

    def expect_client_operation(klass, name = nil)
      ExpectStub.new(klass, name)
    end

    def unstub_all
      allow(Evil::Client::Container::Operation)
        .to receive(:new)
        .and_call_original
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
evil-client-3.2.0 lib/evil/client/rspec.rb
evil-client-3.1.0 lib/evil/client/rspec.rb
evil-client-3.0.4 lib/evil/client/rspec.rb
evil-client-3.0.3 lib/evil/client/rspec.rb
evil-client-3.0.2 lib/evil/client/rspec.rb
evil-client-3.0.1 lib/evil/client/rspec.rb
evil-client-3.0.0 lib/evil/client/rspec.rb
evil-client-2.1.1 lib/evil/client/rspec.rb
evil-client-2.1.0 lib/evil/client/rspec.rb
evil-client-2.0.0 lib/evil/client/rspec.rb
evil-client-1.1.0 lib/evil/client/rspec.rb