From 747d7294cd451d48061185199254bf3af3cdc225 Mon Sep 17 00:00:00 2001 From: mahula Date: Wed, 7 Jun 2023 11:48:52 +0200 Subject: [PATCH] remove async from step definition file --- .../Post.Create/the_post_was_saved_successfully.js | 2 +- .../common/I_choose_the_following_text_as_content.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cypress/support/step_definitions/Post.Create/the_post_was_saved_successfully.js b/cypress/support/step_definitions/Post.Create/the_post_was_saved_successfully.js index 987e477d4..50e414650 100644 --- a/cypress/support/step_definitions/Post.Create/the_post_was_saved_successfully.js +++ b/cypress/support/step_definitions/Post.Create/the_post_was_saved_successfully.js @@ -1,6 +1,6 @@ import { Then } from "@badeball/cypress-cucumber-preprocessor"; -Then("the post was saved successfully", async () => { +Then("the post was saved successfully", () => { cy.task('getValue', 'lastPost').then(lastPost => { cy.get(".base-card > .title").should("contain", lastPost.title); cy.get(".content").should("contain", lastPost.content); diff --git a/cypress/support/step_definitions/common/I_choose_the_following_text_as_content.js b/cypress/support/step_definitions/common/I_choose_the_following_text_as_content.js index 0cb974004..51d77d8e1 100644 --- a/cypress/support/step_definitions/common/I_choose_the_following_text_as_content.js +++ b/cypress/support/step_definitions/common/I_choose_the_following_text_as_content.js @@ -1,6 +1,6 @@ import { When } from "@badeball/cypress-cucumber-preprocessor"; -When("I choose the following text as content:", async text => { +When("I choose the following text as content:", text => { cy.task('getValue', 'lastPost').then(lastPost => { lastPost.content = text.replace("\n", " "); cy.task('pushValue', { name: 'lastPost', value: lastPost })