Sha256: eaf9d1d271e889fcf0944830dbfd7a279abd801b6b5f62a894ba60f2b199e4e1
Contents?: true
Size: 755 Bytes
Versions: 9
Compression:
Stored size: 755 Bytes
Contents
require 'spec_helper' describe Bogus::ResetsOverwrittenClasses do let(:classes) { [['Foo', :foo], ['Bar', :bar]] } let(:overwritten_classes) { stub } let(:overwrites_classes) { stub } let(:resets_overwritten_classes) { isolate(Bogus::ResetsOverwrittenClasses) } before do stub(overwritten_classes).classes { classes } stub(overwritten_classes).clear stub(overwrites_classes).overwrite resets_overwritten_classes.reset end it "overwrites back all of the overwritten classes" do overwrites_classes.should have_received.overwrite('Foo', :foo) overwrites_classes.should have_received.overwrite('Bar', :bar) end it "clears the overwritten classes" do overwritten_classes.should have_received.clear end end
Version data entries
9 entries across 9 versions & 1 rubygems