Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Added Unison.load_memory_fixtures and .load_database_fixtures

  • Loading branch information...
commit 54e82c8c7a7257cb3528f1c6c078f8f39f5e6e81 1 parent 24dec4e
Nathan Sobo authored
Showing with 22 additions and 0 deletions.
  1. +8 −0 lib/unison.rb
  2. +14 −0 spec/unit/unison_spec.rb
View
8 lib/unison.rb
@@ -59,6 +59,14 @@ def load_fixtures
Relations::Set.load_fixtures
end
+ def load_memory_fixtures
+ Relations::Set.load_memory_fixtures
+ end
+
+ def load_database_fixtures
+ Relations::Set.load_database_fixtures
+ end
+
attr_writer :test_mode
def test_mode?
@test_mode ||= false
View
14 spec/unit/unison_spec.rb
@@ -22,6 +22,20 @@ module Unison
end
end
+ describe ".load_memory_fixtures" do
+ it "delegates to Relations::Set.load_memory_fixtures" do
+ mock.proxy(Relations::Set).load_memory_fixtures
+ Unison.load_memory_fixtures
+ end
+ end
+
+ describe ".load_database_fixtures" do
+ it "delegates to Relations::Set.load_database_fixtures" do
+ mock.proxy(Relations::Set).load_database_fixtures
+ Unison.load_database_fixtures
+ end
+ end
+
describe ".and" do
it "instantiates a Predicates::And with the passed-in arguments" do
Unison.and(predicate_1, predicate_2).should == Unison::Predicates::And.new(predicate_1, predicate_2)

0 comments on commit 54e82c8

Please sign in to comment.
Something went wrong with that request. Please try again.