aboutsummaryrefslogtreecommitdiffstats
path: root/spec/controllers/request_controller_spec.rb
diff options
context:
space:
mode:
authorLouise Crow <louise.crow@gmail.com>2013-06-04 11:49:34 +0100
committerLouise Crow <louise.crow@gmail.com>2013-06-04 11:49:34 +0100
commitf6bb0e5d33ceb5beb80f9561b77c716a04f574a2 (patch)
tree135c5ccefc742e471f4b74ddf0688aace10a70d7 /spec/controllers/request_controller_spec.rb
parentc304f25a8950f61215ef2fae1e7feb71cfbfeb56 (diff)
parent9727c7b62fd3fe7b00cfc64cb4b36ba445a3a960 (diff)
Merge remote-tracking branch 'openaustralia_github/inline_search_method_refactor' into rails-3-develop
Diffstat (limited to 'spec/controllers/request_controller_spec.rb')
-rw-r--r--spec/controllers/request_controller_spec.rb6
1 files changed, 4 insertions, 2 deletions
diff --git a/spec/controllers/request_controller_spec.rb b/spec/controllers/request_controller_spec.rb
index 9cc60a103..122584c7d 100644
--- a/spec/controllers/request_controller_spec.rb
+++ b/spec/controllers/request_controller_spec.rb
@@ -93,8 +93,10 @@ describe RequestController, "when listing recent requests" do
:results => (1..25).to_a.map { |m| { :model => m } },
:matches_estimated => 1000000)
- InfoRequest.should_receive(:full_search).
- with([InfoRequestEvent]," (variety:sent OR variety:followup_sent OR variety:response OR variety:comment)", "created_at", anything, anything, anything, anything).
+ ActsAsXapian::Search.should_receive(:new).
+ with([InfoRequestEvent]," (variety:sent OR variety:followup_sent OR variety:response OR variety:comment)",
+ :sort_by_prefix => "created_at", :offset => 0, :limit => 25, :sort_by_ascending => true,
+ :collapse_by_prefix => "request_collapse").
and_return(xap_results)
get :list, :view => 'all'
assigns[:list_results].size.should == 25