Jesus Cuadro
Pasando el scenario outline en el feature
# features/Login.feature @probando Scenario Outline: Scenario Outline for login Given Im on the right When I fill the form with my <Email> and my <Password> Then I should see the dashboard page Examples: | Email | Password | | jexusmaster@gmail.com | Jexxus2334 | | jesuscuadro@gmail.com | Jexxus2334 | | juanito@gmail.com | Jexxus2334 | | pepito@gmail.com | Jexxus2334 | | camila@gmail.com | Jexxus2334 | | sadsadasr@gmail.com | Jexxus2334 |
// Formas de pasar el email y password desde los // steps-definitions con expresiones regulares When(/^I fill the form with my email: "([^"]*)" and my password: "([^"]*)"$/, (email, password) => { loginPage.login(email, password); }); When(/^I fill the form with my (.*) and my (.*)$/, (email, password) => { loginPage.login(email, password); });
"test-dev": "npx codeceptjs run --grep '@probando' --verbose", // Colocarlo en el package.json para lograr ejecutar el scenario