aboutsummaryrefslogtreecommitdiffstats
path: root/spec/controllers/general_controller_spec.rb
diff options
context:
space:
mode:
authorRobin Houston <robin.houston@gmail.com>2012-01-27 09:36:02 +0000
committerRobin Houston <robin.houston@gmail.com>2012-01-27 09:36:02 +0000
commit347a24ccfe0881b494044778cae64809d3e001c0 (patch)
treed9cc2cad0d41804fa8c43dfc5189a27d454fae14 /spec/controllers/general_controller_spec.rb
parent5d77eb0b4580bf6fb13e2fca2e9469b84f8315ff (diff)
More test data and a new test
This is a test for what I thought issue #370 might be. However this test is passing, so it isn’t that.
Diffstat (limited to 'spec/controllers/general_controller_spec.rb')
-rw-r--r--spec/controllers/general_controller_spec.rb6
1 files changed, 4 insertions, 2 deletions
diff --git a/spec/controllers/general_controller_spec.rb b/spec/controllers/general_controller_spec.rb
index c4fd46c14..b067707de 100644
--- a/spec/controllers/general_controller_spec.rb
+++ b/spec/controllers/general_controller_spec.rb
@@ -115,9 +115,11 @@ describe GeneralController, "when searching" do
rebuild_xapian_index
end
- it 'should list the successful request first' do
+ it 'should list the newest successful request first' do
+ # Make sure the newest is listed first even if an older one has an even newer comment:
+ # https://github.com/sebbacon/alaveteli/issues/370
get :frontpage
- assigns[:request_events].first.info_request.should == info_requests(:boring_request)
+ assigns[:request_events].first.info_request.should == info_requests(:another_boring_request)
end
end