mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
13 lines
380 B
JavaScript
13 lines
380 B
JavaScript
import { Given } from "cypress-cucumber-preprocessor/steps";
|
|
import narrator from "../data/narrator";
|
|
|
|
Given("I am logged in", () => {
|
|
cy.neode()
|
|
.first("User", { name: narrator.name })
|
|
.then(user => {
|
|
return new Cypress.Promise((resolve, reject) => {
|
|
return user.toJson().then((user) => resolve(user))
|
|
})
|
|
})
|
|
.then(user => cy.login(user))
|
|
}); |