From 31872174e3a2c54e8422b84e3f0933df6b1688ba Mon Sep 17 00:00:00 2001 From: Anthony Davis Date: Thu, 17 Jul 2014 20:35:12 -0500 Subject: [PATCH] VRFS-1741 - this checks resque queues, will fail if any > 5 --- monitor/spec/production_spec.rb | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/monitor/spec/production_spec.rb b/monitor/spec/production_spec.rb index 060c65b0b..5236173a5 100755 --- a/monitor/spec/production_spec.rb +++ b/monitor/spec/production_spec.rb @@ -96,4 +96,14 @@ describe "Deployed site at #{www}", :js => true, :type => :feature, :capybara_fe in_client(user2) { sign_out_poltergeist } end + let(:queue_limit) { 5 } + + it "should not find any stuck workers in resque queues" do + page.driver.basic_authorize('jamjam','blueberryjam') + visit '/admin/resque/queues' + page.all('tr:not(.failure) .size').each do |job_queue| + expect(job_queue.text.to_i).to be < queue_limit + end + #this (maybe mistakenly) ignores the .failure queue, since it can be in the hundreds - VRFS-1930 + end end