diff --git a/app/components/admin/tenants/index_component.html.erb b/app/components/admin/tenants/index_component.html.erb
index 655603ddc..ad5f43ea9 100644
--- a/app/components/admin/tenants/index_component.html.erb
+++ b/app/components/admin/tenants/index_component.html.erb
@@ -17,11 +17,9 @@
| <%= tenant.name %> |
<%= tenant.schema %> |
- <%= tenant.host %> |
+ <%= link_to tenant.host, root_url(host: tenant.host) %> |
- <%= render Admin::TableActionsComponent.new(tenant, actions: [:edit]) do |actions| %>
- <%= actions.action(:show, text: t("admin.shared.view"), path: root_url(host: tenant.host)) %>
- <% end %>
+ <%= render Admin::TableActionsComponent.new(tenant, actions: [:edit]) %>
|
<% end %>
diff --git a/spec/system/admin/tenants_spec.rb b/spec/system/admin/tenants_spec.rb
index bbc0bbf76..92096261b 100644
--- a/spec/system/admin/tenants_spec.rb
+++ b/spec/system/admin/tenants_spec.rb
@@ -19,11 +19,7 @@ describe "Tenants", :admin, :seed_tenants do
expect(page).to have_content "Tenant created successfully"
- within("tr", text: "earth") do
- expect(page).to have_content "earth.lvh.me"
-
- click_link "View"
- end
+ click_link "earth.lvh.me"
expect(current_host).to eq "http://earth.lvh.me"
expect(page).to have_current_path root_path
@@ -38,11 +34,7 @@ describe "Tenants", :admin, :seed_tenants do
fill_in "Name", with: "Earthlings"
click_button "Create tenant"
- within("tr", text: "earth") do
- expect(page).to have_content "earth.lvh.me"
-
- click_link "View"
- end
+ click_link "earth.lvh.me"
expect(current_host).to eq "http://earth.lvh.me"
expect(page).to have_current_path root_path
@@ -65,7 +57,7 @@ describe "Tenants", :admin, :seed_tenants do
expect(page).to have_content "Tenant updated successfully"
- within("tr", text: "the-moon") { click_link "View" }
+ click_link "the-moon.lvh.me"
expect(current_host).to eq "http://the-moon.lvh.me"
expect(page).to have_current_path root_path