Skip to content

Commit 701691c

Browse files
committed
ajustes
1 parent 84770f5 commit 701691c

2 files changed

Lines changed: 18 additions & 1 deletion

File tree

pages/LoginPage.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { AIService } from "../services/AIService";
55
export class LoginPage extends BasePage {
66
private readonly usernameInput = "#user-name";
77
private readonly passwordInput = "#password";
8-
private readonly loginButton = "#login-button-quebrei";
8+
private readonly loginButton = "#login-button";
99
private readonly inventoryContainer = "#inventory_container";
1010

1111
constructor(page: Page, ai: AIService) {

tests/e2e/support/world.ts

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { setWorldConstructor, World, IWorldOptions } from '@cucumber/cucumber';
2+
import { AllureCucumberWorld } from 'allure-cucumberjs';
3+
import { PageManager } from '../../../pages/PageManager';
4+
import { Page } from '@playwright/test';
5+
6+
// Extendemos a classe do Allure para ganhar os poderes de .label() e .epic()
7+
export class CustomWorld extends AllureCucumberWorld {
8+
// Declaramos as propriedades que usamos nos Hooks para o TypeScript não reclamar
9+
page?: Page;
10+
pageManager?: PageManager;
11+
12+
constructor(options: IWorldOptions) {
13+
super(options);
14+
}
15+
}
16+
17+
setWorldConstructor(CustomWorld);

0 commit comments

Comments
 (0)