From 119e542e8669a7ffa8c4c0328fdc4d600c7bc6a9 Mon Sep 17 00:00:00 2001 From: mattwr18 Date: Mon, 17 Feb 2020 20:51:13 +0100 Subject: [PATCH] Fix syntax error --- cypress/integration/common/steps.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/cypress/integration/common/steps.js b/cypress/integration/common/steps.js index 0245da208..11feb4eaf 100644 --- a/cypress/integration/common/steps.js +++ b/cypress/integration/common/steps.js @@ -230,15 +230,17 @@ Given("we have the following comments in our database:", table => { }); Given("we have the following posts in our database:", table => { - return new Cypress.Promise((resolve, reject) => { cy.factory().build('category', { id: `cat-456`, name: "Just For Fun", slug: `just-for-fun`, icon: "smile" }).then(categoryJson => { - categoryJson.toJson().then(category => resolve(category)) - }).then(category => { + return new Cypress.Promise((resolve, _reject) => { + return categoryJson.toJson().then(category => resolve(category)) + }) + }) + .then(category => { table.hashes().forEach((attributesOrOptions, i) => { cy.factory().build("post", { ...attributesOrOptions,