Skip to content

Commit 69f6187

Browse files
committed
test(cat-voices): add readme file
1 parent 45296be commit 69f6187

File tree

3 files changed

+57
-2
lines changed

3 files changed

+57
-2
lines changed
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
# Catalyst Voices E2E Tests
2+
3+
End-to-end tests for the Catalyst Voices web application using Playwright.
4+
Unlike regular Playwright setups, this project will connect to already existing browser binary via CDP
5+
and the app will run locally.
6+
7+
## Scope
8+
9+
These tests cover browser-based end-to-end workflows for the Catalyst Voices application:
10+
11+
* **Cardano wallet integration testing** (Lace, Eternl, Yoroi, Nufi)
12+
* **User authentication and account management**
13+
* **Cross-environment testing** (dev, staging, prod)
14+
* **Browser extension interaction**
15+
* **Application title and basic navigation**
16+
17+
## Building & Setup
18+
19+
### Prerequisites
20+
21+
* **Node.js** (v18 or higher)
22+
* **npm** package manager
23+
* **Chrome for testing** ([Download manually](https://googlechromelabs.github.io/chrome-for-testing/))
24+
* Ability to run the app locally (Check `catalyst_voices/README.md` for instructions)
25+
26+
### Installation
27+
28+
1. Run the app locally:
29+
30+
This ensures the app will be running on port 5555.
31+
32+
```bash
33+
cd catalyst_voices/apps/voices &&
34+
flutter run --flavor preprod --web-port 5555
35+
--web-header "Cross-Origin-Opener-Policy=same-origin"
36+
--web-header "Cross-Origin-Embedder-Policy=require-corp"
37+
-d web-server lib/configs/main.dart
38+
```
39+
40+
2. In new terminal, navigate to the e2e tests directory:
41+
42+
```bash
43+
cd catalyst_voices/apps/voices/e2e_tests
44+
```
45+
46+
3. Install dependencies:
47+
48+
```bash
49+
npm install
50+
```
51+
52+
4. Run the e2e tests:
53+
54+
```bash
55+
npx playwright test
56+
```

catalyst_voices/apps/voices/e2e_tests/fixtures/endpoint-fixtures.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ type EndpointFixtures = {
1010
export const test = base.extend<EndpointFixtures>({
1111
appBaseURL: async ({}, use) => {
1212
const baseURL =
13-
process.env.APP_URL || "https://app.dev.projectcatalyst.io/";
13+
process.env.APP_URL || "localhost:5555";
1414
await use(baseURL);
1515
},
1616
});

catalyst_voices/apps/voices/e2e_tests/tests/onboarding.spec.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,5 @@ test.describe("Onboarding - ", () => {
1010
await page
1111
.locator("//*[@aria-label='Enable accessibility']")
1212
.evaluate((element: HTMLElement) => element.click());
13-
await page.locator("#flt-semantic-node-24").waitFor({ state: "visible" });
1413
});
1514
});

0 commit comments

Comments
 (0)