Browse files

Merge remote-tracking branch 'jtolds/master'

  • Loading branch information...
2 parents 3c09121 + 14590b4 commit 6c049968ecf5a27164048bfebacb98105c9968b3 @netzpirat netzpirat committed Dec 14, 2011
Showing with 3 additions and 7 deletions.
  1. +3 −7 spec/guard/coffeescript/inspector_spec.rb
View
10 spec/guard/coffeescript/inspector_spec.rb
@@ -2,7 +2,7 @@
describe Guard::CoffeeScript::Inspector do
before do
- Dir.stub(:glob).and_return 'a.coffee'
+ File.should_receive(:exists?).with("a.coffee").and_return true
end
let(:inspector) { Guard::CoffeeScript::Inspector }
@@ -17,12 +17,8 @@
end
it 'removes non-coffee files' do
- inspector.clean(['a.coffee', 'b.txt']).should == ['a.coffee']
- end
-
- it 'frees up the list of coffee script files' do
- inspector.should_receive(:clear_coffee_files_list)
- inspector.clean(['a.coffee'])
+ File.should_receive(:exists?).with("doesntexist.coffee").and_return false
+ inspector.clean(['a.coffee', 'b.txt', 'doesntexist.coffee']).should == ['a.coffee']
end
end

0 comments on commit 6c04996

Please sign in to comment.