Skip to content

Commit e17fcb8

Browse files
docs: update E2E - we deprecated Internet Identity for local dev
Signed-off-by: David Dal Busco <david.dalbusco@outlook.com>
1 parent 0fd68d7 commit e17fcb8

1 file changed

Lines changed: 14 additions & 7 deletions

File tree

docs/guides/e2e.md

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,23 +24,30 @@ That being said, integrating authentication is easier in Playwright given that a
2424

2525
## Authentication
2626

27-
If your application require authentication, we recommend using the Playwright plugin for Internet Identity maintained by the DFINITY foundation:
27+
If your application require authentication, we recommend using our Playwright plugin for sign-in in development:
2828

29-
👉 [github.com/dfinity/internet-identity-playwright](https://github.com/dfinity/internet-identity-playwright)
29+
👉 [github.com/junobuild/emulator-playwright](https://github.com/junobuild/emulator-playwright)
3030

31-
It handles the full login flow programmatically, allowing your tests to sign in without user interaction.
31+
It handles the full login flow programmatically, allowing your tests to sign in without user interaction. Under the hood, it uses the `dev` option of the `signIn` function:
32+
33+
```typescript
34+
import { signIn } from "@junobuild/core";
35+
36+
await signIn({ dev: {} });
37+
```
3238

3339
### Example usage
3440

3541
After installing the plugin, you can write a test like this:
3642

3743
```typescript
38-
import { testWithII } from "@dfinity/internet-identity-playwright";
44+
import { initSatelliteSuite } from "@junobuild/emulator-playwright";
45+
import { test } from "@playwright/test";
3946

40-
testWithII("should sign-in with a new user", async ({ page, iiPage }) => {
41-
await page.goto("/");
47+
const getPages = initSatelliteSuite();
4248

43-
await iiPage.signInWithNewIdentity();
49+
test("...", async () => {
50+
const { satelliteId, cliPage } = getPages();
4451
});
4552
```
4653

0 commit comments

Comments
 (0)