Sha256: 1581cbbd428e8d573a1e2c2874524b072d4d83a1d7b15c61b4fa83ceaef77e09

Contents?: true

Size: 606 Bytes

Versions: 11

Compression:

Stored size: 606 Bytes

Contents

# frozen_string_literal: true

require 'spec_helper'

RSpec.describe Sinclair::Matchers do
  let(:klass)         { Class.new }
  let(:method)        { :the_method }
  let(:value)         { Random.rand(100) }
  let(:builder_class) { DefaultValue }
  let(:builder)       { builder_class.new(klass, method, value) }
  let(:instance)      { klass.new }

  context 'when the builder runs' do
    it do
      expect { builder.build }.to add_method(method).to(instance)
    end
  end

  context 'when the builder runs' do
    it do
      expect { builder.build }.to add_method(method).to(klass)
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
sinclair-1.5.0 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.4.2 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.4.1 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.4.0 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.3.4 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.3.3 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.3.2 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.3.1 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.3.0 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.2.1 spec/integration/readme/sinclair/matchers_spec.rb
sinclair-1.2.0 spec/integration/readme/sinclair/matchers_spec.rb