[ARVADOS] updated: d88316705b23d1022ee2167c7ed0e5cf5e460cbe

git at public.curoverse.com git at public.curoverse.com
Fri Nov 27 01:52:14 EST 2015


Summary of changes:
 services/api/test/unit/crunch_dispatch_test.rb | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

       via  d88316705b23d1022ee2167c7ed0e5cf5e460cbe (commit)
      from  40f063c4f6aa35c641650c80751392292e151acb (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit d88316705b23d1022ee2167c7ed0e5cf5e460cbe
Author: Tom Clegg <tom at curoverse.com>
Date:   Fri Nov 27 02:01:42 2015 -0500

    Clear job queue before testing crunch-dispatch start/stop.
    
    Otherwise, it might get as far as starting jobs before we send TERM.
    
    No issue # but see build 2249.

diff --git a/services/api/test/unit/crunch_dispatch_test.rb b/services/api/test/unit/crunch_dispatch_test.rb
index 9e68db3..f01e50d 100644
--- a/services/api/test/unit/crunch_dispatch_test.rb
+++ b/services/api/test/unit/crunch_dispatch_test.rb
@@ -81,6 +81,14 @@ class CrunchDispatchTest < ActiveSupport::TestCase
             end
           end
           ActiveRecord::Base.establish_connection
+
+          # Make sure the queue is empty. We don't really want to
+          # dispatch any jobs.
+          act_as_user users(:admin) do
+            Job.destroy_all
+            PipelineInstance.destroy_all
+          end
+
           CrunchDispatch.new.run []
         ensure
           Process.exit!
@@ -92,7 +100,7 @@ class CrunchDispatchTest < ActiveSupport::TestCase
     ensure
       Process.kill("TERM", pid)
     end
-    assert_with_timeout 5, "Dispatch did not unlock #{lockfile}" do
+    assert_with_timeout 20, "Dispatch did not unlock #{lockfile}" do
       can_lock(lockfile)
     end
   end

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list