[ARVADOS] updated: 15fef38119793831a6717a98762c60aacb5d0264

git at public.curoverse.com git at public.curoverse.com
Wed Apr 8 10:39:19 EDT 2015


Summary of changes:
 apps/workbench/app/views/application/_content.html.erb   | 2 +-
 apps/workbench/test/integration/anonymous_access_test.rb | 7 ++++---
 2 files changed, 5 insertions(+), 4 deletions(-)

       via  15fef38119793831a6717a98762c60aacb5d0264 (commit)
      from  ae2787c96b41c3844193cba3e2dddffabd98be33 (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 15fef38119793831a6717a98762c60aacb5d0264
Author: Radhika Chippada <radhika at curoverse.com>
Date:   Wed Apr 8 10:24:30 2015 -0400

    5365: Additional test verifications for Log tab display.

diff --git a/apps/workbench/app/views/application/_content.html.erb b/apps/workbench/app/views/application/_content.html.erb
index 03dff65..3cfadee 100644
--- a/apps/workbench/app/views/application/_content.html.erb
+++ b/apps/workbench/app/views/application/_content.html.erb
@@ -9,7 +9,7 @@
       <% data_toggle = "tab" %>
       <% tab_tooltip = "" %>
 
-      <% if (pane_name == "Log") and (@object.owner_uuid != current_user)
+      <% if (pane_name == "Log") and !(ArvadosBase.find(@object.owner_uuid).writable_by.include?(current_user.andand.uuid) rescue nil)
           if controller.model_class.to_s == 'Job'
             if @object.log and !@object.log.empty?
               logCollection = Collection.find? @object.log
diff --git a/apps/workbench/test/integration/anonymous_access_test.rb b/apps/workbench/test/integration/anonymous_access_test.rb
index 8000e93..20bb0fd 100644
--- a/apps/workbench/test/integration/anonymous_access_test.rb
+++ b/apps/workbench/test/integration/anonymous_access_test.rb
@@ -186,7 +186,8 @@ class AnonymousAccessTest < ActionDispatch::IntegrationTest
   [
     ['pipeline_in_publicly_accessible_project', true],
     ['pipeline_in_publicly_accessible_project_but_other_objects_elsewhere', false],
-    ['pipeline_in_publicly_accessible_project_but_other_objects_elsewhere', false, 'admin'],
+    ['pipeline_in_publicly_accessible_project_but_other_objects_elsewhere', false, 'spectator'],
+    ['pipeline_in_publicly_accessible_project_but_other_objects_elsewhere', true, 'admin'],
 
     ['completed_job_in_publicly_accessible_project', true],
     ['job_in_publicly_accessible_project_but_other_objects_elsewhere', false],
@@ -211,7 +212,7 @@ class AnonymousAccessTest < ActionDispatch::IntegrationTest
       # click job link, if in pipeline page
       click_link 'foo' if pipeline_page
 
-      if objects_readable or user
+      if objects_readable
         if pipeline_page
           assert_text 'This pipeline was created from'
           assert_selector 'a', object['components']['foo']['job']['uuid']
@@ -231,7 +232,7 @@ class AnonymousAccessTest < ActionDispatch::IntegrationTest
       end
 
       click_link 'Log'
-      if objects_readable or user
+      if objects_readable
         assert_no_text 'foo'  # should be in Log tab
         assert_text 'stderr crunchstat'   if pipeline_page
       else

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list