-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
front: editor: split tests in separated files
and add line feeds in EOF
- Loading branch information
1 parent
5f3df61
commit 1d6c58a
Showing
4 changed files
with
1,836 additions
and
1,900 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
|
||
import {expect, test} from '@playwright/test'; | ||
import {PlaywrightEditorPage} from "./pages/editor-page-model"; | ||
|
||
test.describe('Testing the Editor app', () => { | ||
test('Testing there is no error by default in the Editor', async ({page}) => { | ||
const playwrightEditorPage = new PlaywrightEditorPage(page); | ||
await playwrightEditorPage.goToEditorPage() | ||
|
||
await expect( | ||
playwrightEditorPage.getErrorBox | ||
).not.toBeVisible(); | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
|
||
|
||
/* eslint-disable import/prefer-default-export */ | ||
import { expect, Locator, Page } from '@playwright/test'; | ||
|
||
export class PlaywrightEditorPage { | ||
// The current page object | ||
readonly page: Page; | ||
readonly getErrorBox: Locator; | ||
|
||
constructor(page: Page) { | ||
this.page = page; | ||
this.getErrorBox = page.locator('.error-box'); | ||
} | ||
// Navigate to the Home page | ||
async goToEditorPage() { | ||
await this.page.goto('/editor'); | ||
} | ||
|
||
} |
Oops, something went wrong.