Merge branch 'master' into 10645-cr-mounts-display
[arvados.git] / apps / workbench / test / integration / repositories_test.rb
index 1e1a118a7a5ec6d8e9610c3d244ddd9a7bafd0dd..49654a86887fa033cb342a844cf35b385002f438 100644 (file)
@@ -15,7 +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_object_using(user, 'repositories', 'foo', 'push_url')
+      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)
@@ -28,7 +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_object_using(user, 'repositories', 'foo', 'push_url')
+      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)
@@ -36,7 +38,8 @@ class RepositoriesTest < ActionDispatch::IntegrationTest
   end
 
   test "spectator does not see repository sharing tab" do
-    show_object_using("spectator", 'repositories', 'arvados', 'push_url')
+    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