From 7e9461b62832cea355ae2659a0ffb9a340962601 Mon Sep 17 00:00:00 2001 From: Brian Austin Date: Fri, 24 Jan 2025 09:42:41 -0500 Subject: [PATCH] Use existing step --- features/admins/admin_invitations.feature | 4 ++-- features/other_a/invite_use.feature | 4 ++-- features/step_definitions/invite_steps.rb | 4 ---- 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/features/admins/admin_invitations.feature b/features/admins/admin_invitations.feature index 35258386b8e..91694b0d324 100644 --- a/features/admins/admin_invitations.feature +++ b/features/admins/admin_invitations.feature @@ -474,7 +474,7 @@ Feature: Admin Actions to Manage Invitations And the user "invitee" exists and is activated And an invitation created by "creator" and used by "invitee" And I am logged in as a "" admin - When I manage invitations belonging to "creator" + When I go to creator's manage invitations page Then I should see "invitee" When I view the most recent invitation for "creator" Then I should see "invitee" @@ -483,7 +483,7 @@ Feature: Admin Actions to Manage Invitations When I am logged in as "invitee" And "invitee" deletes their account And I am logged in as a "" admin - And I manage invitations belonging to "creator" + And I go to creator's manage invitations page Then I should see "(Deleted)" But I should not see "invitee" When I view the most recent invitation for "creator" diff --git a/features/other_a/invite_use.feature b/features/other_a/invite_use.feature index 48ac211e93e..54054d89e6c 100644 --- a/features/other_a/invite_use.feature +++ b/features/other_a/invite_use.feature @@ -35,14 +35,14 @@ I want to use an invitation to create an account And the user "invitee" exists and is activated And an invitation created by "creator" and used by "invitee" And I am logged in as "creator" - When I manage invitations belonging to "creator" + When I go to creator's manage invitations page Then I should see "invitee" When I view the most recent invitation for "creator" Then I should see "invitee" When I am logged in as "invitee" And "invitee" deletes their account And I am logged in as "creator" - And I manage invitations belonging to "creator" + And I go to creator's manage invitations page Then I should see "Deleted User" But I should not see "invitee" When I view the most recent invitation for "creator" diff --git a/features/step_definitions/invite_steps.rb b/features/step_definitions/invite_steps.rb index dc885433d1c..2d9bfc867e8 100644 --- a/features/step_definitions/invite_steps.rb +++ b/features/step_definitions/invite_steps.rb @@ -162,10 +162,6 @@ def invite(attributes = {}) click_button("Look me up") end -When "I manage invitations belonging to {string}" do |creator| - visit manage_user_invitations_path(creator) -end - When "I view the most recent invitation for {string}" do |creator| user = User.find_by(login: creator) invitation = user.invitations.last