Use regex to determine whether to print help text for arvbash.sh. refs #10655
[arvados.git] / apps / workbench / test / integration / repositories_test.rb
index 5648c71be9efd3a131572da25a428b79b387a648..49654a86887fa033cb342a844cf35b385002f438 100644 (file)
@@ -15,8 +15,8 @@ class RepositoriesTest < ActionDispatch::IntegrationTest
     test "#{user} can manage sharing for another user" do
       add_user = api_fixture('users')['future_project_user']
       new_name = ["first_name", "last_name"].map { |k| add_user[k] }.join(" ")
-
-      show_repository_using(user, 'foo')
+      show_object_using(user, 'repositories', 'foo',
+                        api_fixture('repositories')['foo']['name'])
       click_on "Sharing"
       add_share_and_check("users", new_name, add_user)
       modify_share_and_check(new_name)
@@ -29,8 +29,8 @@ class RepositoriesTest < ActionDispatch::IntegrationTest
   ].each do |user|
     test "#{user} can manage sharing for another group" do
       new_name = api_fixture('groups')['future_project_viewing_group']['name']
-
-      show_repository_using("active", 'foo')
+      show_object_using(user, 'repositories', 'foo',
+                        api_fixture('repositories')['foo']['name'])
       click_on "Sharing"
       add_share_and_check("groups", new_name)
       modify_share_and_check(new_name)
@@ -38,7 +38,8 @@ class RepositoriesTest < ActionDispatch::IntegrationTest
   end
 
   test "spectator does not see repository sharing tab" do
-    show_repository_using("spectator")
+    show_object_using('spectator', 'repositories', 'arvados',
+                      api_fixture('repositories')['arvados']['name'])
     assert(page.has_no_link?("Sharing"),
            "read-only repository user sees sharing tab")
   end