Open platform to collect and prioritize feedback
Fixed the UI test
Matt Roberts68fd543ab0be
diff --git a/e2e/features/ui/post.feature b/e2e/features/ui/post.featureindex db9ed468b..ba0d12d8b 100644--- a/e2e/features/ui/post.feature+++ b/e2e/features/ui/post.feature@@ -8,7 +8,7 @@ Feature: PostAnd I click submit new postThen I should be on the show post pageAnd I should see "Feature Request Example" as the post title- And I should see 1 vote+ And I should see 1 vote(s)Scenario: Non-logged in user can view a postGiven I go to the home page@@ -16,4 +16,4 @@ Feature: PostAnd I click on the first postThen I should be on the show post pageAnd I should see "Feature Request Example" as the post title- And I should see 1 vote\ No newline at end of file+ And I should see 1 vote(s)\ No newline at end of filediff --git a/e2e/step_definitions/show_post.steps.ts b/e2e/step_definitions/show_post.steps.tsindex 7998b4b9a..78d2b0937 100644--- a/e2e/step_definitions/show_post.steps.ts+++ b/e2e/step_definitions/show_post.steps.ts@@ -13,5 +13,5 @@ Then("I should see {string} as the post title", async function (this: FiderWorld})Then("I should see {int} vote\\(s)", async function (this: FiderWorld, voteCount: number) {- await expect(this.page.getByText(`${voteCount} votes`, { exact: true })).toBeVisible()+ await expect(this.page.getByText(`${voteCount}${voteCount === 1 ? "Vote" : "Votes"}`, { exact: true })).toBeVisible()})