aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Landauer <matthew@openaustralia.org>2013-01-29 13:05:21 +1100
committerMatthew Landauer <matthew@openaustralia.org>2013-01-29 13:05:21 +1100
commit30ef245a8ccb31c120a35eef1df35478877b43bf (patch)
tree858e6003e969817ec992761f2e3d8a0d5bfbc4cb
parent10e7fe18316f03b525a467c3d8a6e2115391c83e (diff)
When mocking ActsAsXapian can't use mock_model because it's not a model
-rw-r--r--spec/controllers/request_controller_spec.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/controllers/request_controller_spec.rb b/spec/controllers/request_controller_spec.rb
index 847031674..53bae9f9c 100644
--- a/spec/controllers/request_controller_spec.rb
+++ b/spec/controllers/request_controller_spec.rb
@@ -91,7 +91,7 @@ describe RequestController, "when listing recent requests" do
end
it "should assign the first page of results" do
- xap_results = mock_model(ActsAsXapian::Search,
+ xap_results = mock(ActsAsXapian::Search,
:results => (1..25).to_a.map { |m| { :model => m } },
:matches_estimated => 1000000)
@@ -104,7 +104,7 @@ describe RequestController, "when listing recent requests" do
end
it "should return 404 for pages we don't want to serve up" do
- xap_results = mock_model(ActsAsXapian::Search,
+ xap_results = mock(ActsAsXapian::Search,
:results => (1..25).to_a.map { |m| { :model => m } },
:matches_estimated => 1000000)
lambda {