[ARVADOS] updated: 2.1.0-27-g2221946b2

Git user git at public.arvados.org
Wed Oct 21 21:19:16 UTC 2020


Summary of changes:
 apps/workbench/app/controllers/container_requests_controller.rb   | 8 ++++----
 .../test/controllers/container_requests_controller_test.rb        | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)

       via  2221946b2e7322f9680f5d9617ba98b620158c0d (commit)
      from  1008fd532fb9229b0fc0c1d9afb547bb6cfe4244 (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 2221946b2e7322f9680f5d9617ba98b620158c0d
Author: Peter Amstutz <peter.amstutz at curii.com>
Date:   Wed Oct 21 17:19:05 2020 -0400

    17010: Fix tests
    
    Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <peter.amstutz at curii.com>

diff --git a/apps/workbench/app/controllers/container_requests_controller.rb b/apps/workbench/app/controllers/container_requests_controller.rb
index c42e93375..c217eb977 100644
--- a/apps/workbench/app/controllers/container_requests_controller.rb
+++ b/apps/workbench/app/controllers/container_requests_controller.rb
@@ -152,7 +152,7 @@ class ContainerRequestsController < ApplicationController
     @object = ContainerRequest.new
 
     # set owner_uuid to that of source, provided it is a project and writable by current user
-    if params[:work_unit][:owner_uuid]
+    if params[:work_unit].andand[:owner_uuid]
       @object.owner_uuid = src.owner_uuid = params[:work_unit][:owner_uuid]
     else
       current_project = Group.find(src.owner_uuid) rescue nil
@@ -161,7 +161,8 @@ class ContainerRequestsController < ApplicationController
       end
     end
 
-    if src.command[0] == 'arvados-cwl-runner'
+    command = src.command
+    if command[0] == 'arvados-cwl-runner'
       command.each_with_index do |arg, i|
         if arg.start_with? "--project-uuid="
           command[i] = "--project-uuid=#{@object.owner_uuid}"
@@ -174,11 +175,10 @@ class ContainerRequestsController < ApplicationController
 
     # By default the copied CR won't be reusing containers, unless use_existing=true
     # param is passed.
-    command = src.command
     if params[:use_existing]
       @object.use_existing = true
       # Pass the correct argument to arvados-cwl-runner command.
-      if src.command[0] == 'arvados-cwl-runner'
+      if command[0] == 'arvados-cwl-runner'
         command = src.command - ['--disable-reuse']
         command.insert(1, '--enable-reuse')
       end
diff --git a/apps/workbench/test/controllers/container_requests_controller_test.rb b/apps/workbench/test/controllers/container_requests_controller_test.rb
index 140b59fa5..c4a723930 100644
--- a/apps/workbench/test/controllers/container_requests_controller_test.rb
+++ b/apps/workbench/test/controllers/container_requests_controller_test.rb
@@ -42,7 +42,7 @@ class ContainerRequestsControllerTest < ActionController::TestCase
     get :show, params: {id: uuid}, session: session_for(:active)
     assert_response :success
 
-    assert_includes @response.body, "action=\"/container_requests/#{uuid}/copy\""
+    assert_includes @response.body, "action_href=%2Fcontainer_requests%2F#{uuid}%2Fcopy"
   end
 
   test "cancel request for queued container" do

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list