spec/guard/teaspoon/resolver_spec.rb in guard-teaspoon-0.0.3 vs spec/guard/teaspoon/resolver_spec.rb in guard-teaspoon-0.0.4
- old
+ new
@@ -21,8 +21,15 @@
Teaspoon::Suite.should_receive(:resolve_spec_for).with("baz").and_return(suite: "other", path: "baz")
subject.resolve(["foo", "bar", "baz"])
expect(subject.suites).to eq({"default" => ["foo", "bar"], "other" => ["baz"]})
end
+ it "resolves directories" do
+ paths = ["spec/javascripts/my_test_spec.js", "spec/javascripts/my_other_test_spec.js"]
+ Teaspoon::Suite.stub(:resolve_spec_for).and_return(suite: 'default', path: paths)
+ subject.resolve([ 'spec/javascripts' ])
+ expect(subject.suites).to eq({"default" => paths})
+ end
+
end
end