Sha256: e6a71d1c03acbc7361fed49d0af5df9407b22a34a4cc49842c66de74dd83d525
Contents?: true
Size: 780 Bytes
Versions: 8
Compression:
Stored size: 780 Bytes
Contents
# encoding: utf-8 require 'spec_helper' describe Mutant::Matcher::Method::Instance, '.build' do let(:object) { described_class } subject { object.build(cache, scope, method) } let(:cache) { double } let(:scope) do Class.new do include Adamantium def foo end memoize :foo def bar end end end let(:method) do scope.instance_method(method_name) end context 'with adamantium infected scope' do context 'with unmemoized method' do let(:method_name) { :bar } it { should eql(described_class.new(cache, scope, method)) } end context 'with memoized method' do let(:method_name) { :foo } it { should eql(described_class::Memoized.new(cache, scope, method)) } end end end
Version data entries
8 entries across 8 versions & 1 rubygems