-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Playwright E2E tests clean-up. Remove all references to Cypress. (#346)
Following up on #335 and issue #330 - this removes all references to Cypress. Apps incorporating these changes will need to update their environment variables and repository secrets accordingly.
- Loading branch information
Showing
7 changed files
with
10 additions
and
10 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
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 |
---|---|---|
|
@@ -3,11 +3,11 @@ import { test, expect } from '@playwright/test' | |
import dotenv from 'dotenv' | ||
|
||
test('Login workflow', async ({ page }) => { | ||
expect(process.env.CYPRESS_TEST_USER_PASS).toBeTruthy() | ||
expect(process.env.PLAYWRIGHT_TEST_USER_PASS).toBeTruthy() | ||
|
||
await page.goto('/log-in') | ||
await page.getByTestId('email').fill('[email protected]') | ||
await page.getByTestId('password').fill(process.env.CYPRESS_TEST_USER_PASS ?? '') | ||
await page.getByTestId('password').fill(process.env.PLAYWRIGHT_TEST_USER_PASS ?? '') | ||
await page.getByTestId('submit').click() | ||
|
||
await expect(page.getByRole('heading', { name: 'Dashboard' })).toBeVisible() | ||
|
4 changes: 2 additions & 2 deletions
4
{{cookiecutter.project_slug}}/clients/web/vue3/tests/e2e/specs/login.spec.ts
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 |
---|---|---|
@@ -1,11 +1,11 @@ | ||
import { test, expect } from '@playwright/test' | ||
|
||
test('Login workflow', async ({ page }) => { | ||
expect(process.env.CYPRESS_TEST_USER_PASS).toBeTruthy() | ||
expect(process.env.PLAYWRIGHT_TEST_USER_PASS).toBeTruthy() | ||
|
||
await page.goto('/login') | ||
await page.getByPlaceholder('Enter email...').fill('[email protected]') | ||
await page.getByPlaceholder('Enter password...').fill(process.env.CYPRESS_TEST_USER_PASS ?? '') | ||
await page.getByPlaceholder('Enter password...').fill(process.env.PLAYWRIGHT_TEST_USER_PASS ?? '') | ||
await page.getByRole('button', { name: 'Log in' }).click() | ||
|
||
await expect(page.getByRole('heading', { name: 'Dashboard' })).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 |
---|---|---|
|
@@ -9,7 +9,7 @@ | |
}, | ||
"cacheDirectories": [ | ||
"client/node_modules", | ||
".cache/Cypress" | ||
".cache/ms-playwright" | ||
], | ||
"dependencies": {} | ||
} |
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 |
---|---|---|
|
@@ -13,7 +13,7 @@ class Command(BaseCommand): | |
def handle(self, *args, **kwargs): | ||
logger.info(f"Starting management command {__name__}") | ||
superuser_password = config("DJANGO_SUPERUSER_PASSWORD") | ||
playwright_password = config("CYPRESS_TEST_USER_PASS") | ||
playwright_password = config("PLAYWRIGHT_TEST_USER_PASS") | ||
get_user_model().objects.create_superuser( | ||
email="[email protected]", password=superuser_password, first_name="Admin", last_name="ThinkNimble" | ||
) | ||
|