test(FR-2639): add E2E regression for sToken login boundary routes#6865
Merged
graphite-app[bot] merged 1 commit intoApr 24, 2026
Conversation
This was referenced Apr 22, 2026
Contributor
Author
8 tasks
2f4d85c to
08977bf
Compare
9fcac0c to
b229d79
Compare
08977bf to
658c9bd
Compare
b229d79 to
541721c
Compare
5dfc734 to
43f4e07
Compare
3 tasks
43f4e07 to
a231db5
Compare
ca03dc3 to
41da011
Compare
5 tasks
a231db5 to
17f7358
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
Adds Playwright E2E regressions for the new STokenLoginBoundary behavior across LoginView and EduAppLauncher routes, and updates the FR-2616 spec metadata to link the relevant implementation/testing PRs.
Changes:
- Add E2E coverage for sToken boundary behavior on
/and/interactive-login(invalid token UI + URL preservation; non-sToken path still shows login form). - Add E2E coverage for sToken boundary behavior on
/edu-applauncherand/applauncher, including a regression guard ensuring LMS envelope params reachtoken_login. - Extend the draft spec metadata to record PR numbers/URLs and updated notes for Story 2/3.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
e2e/auth/stoken-login.spec.ts |
New regression E2E for LoginView sToken boundary error/URL behavior and non-sToken passthrough. |
e2e/app-launcher/edu-applauncher-stoken.spec.ts |
New regression E2E for EduAppLauncher sToken boundary + POST body forwarding assertions via route mocks. |
.specs/draft-stoken-login-boundary/metadata.json |
Adds PR linkage metadata and updates spec notes for FR-2616 story tracking. |
41da011 to
7fba64c
Compare
17f7358 to
a1a4a7a
Compare
7fba64c to
907c539
Compare
6f5b6cd to
abeb16c
Compare
907c539 to
87f643c
Compare
Merge activity
|
graphite-app Bot
pushed a commit
that referenced
this pull request
Apr 23, 2026
…ary (#6864) Resolves FR-2641, FR-2642 (under Story [FR-2627](https://lablup.atlassian.net/browse/FR-2627), Epic [FR-2616](https://lablup.atlassian.net/browse/FR-2616)) ## Summary Story 3 of Epic FR-2616: route `/edu-applauncher` and `/applauncher` now authenticate through `STokenLoginBoundary` before `EduAppLauncher` mounts. `_token_login` and the manual `backend-ai-connected` dispatch are removed from the component. ### Scope - **Route wrapping** (`react/src/routes.tsx`): both edu-app routes read `sToken` via `useSToken()` and URL params via `useQueryStates(eduAppExtraParamSpec)`, then wrap `EduAppLauncherPage` with `STokenLoginBoundary`. The URL is intentionally not stripped on success (the launcher still passes `sToken` prop through for `eduApp.get_user_credential` and other params drive the launch sequence). - **`EduAppLauncher` cleanup** (`react/src/components/EduAppLauncher.tsx`): - Removed `_token_login()` method and the URL parsing it owned. - Removed the manual `document.dispatchEvent(new CustomEvent('backend-ai-connected'))` call (the boundary now dispatches this exactly once). - **Removed the `auth` stage from `EduAppLaunchStage`** — authentication is no longer represented in the launcher's state machine or its stepper UI. Since the boundary runs `connectViaGQL` before `EduAppLauncher` mounts, the component always starts with a fully authenticated client. - **Deleted `_prepareProjectInformation()`** — `connectViaGQL` already populates `groups` / `groupIds` / `current_group` / `current_group_id` with a superset of the fields this helper fetched. - Proxy URL attach (`_attachProxyURL`) remains but is no longer labeled "auth"; failures now surface under the session step. - The stepper UI drops from 3 steps to 2 (`Preparing Session` → `Launching App`). - **`extraParams` allowlist** (`react/src/routes.tsx:eduAppExtraParamSpec`): added `api_version`, `date`, `endpoint`. These are part of the LMS signing envelope forwarded with `sToken` in the old URL-scan based `_token_login`; the nuqs migration replaced the scan with an explicit allowlist and had dropped them, causing manager-side auth hooks that validate the signature against these fields to reject `token_login` as tampered. ## Test plan - [x] `bash scripts/verify.sh` → `ALL PASS` - [ ] Manual: launch from LMS URL `/edu-applauncher?sToken=<signed>&app=jupyterlab&api_version=...&date=...&endpoint=...&session_id=...` and confirm: - `POST /server/token-login` body contains all extra keys (check DevTools Network tab) - Stepper shows 2 steps ("Preparing Session", "Launching App") — no "Authentication" step - Successful launch opens the app in a new tab - [ ] Regression scenarios covered by PR #6865 E2E: with / without `session_id`, invalid sToken surfaces stepper-integrated error **Checklist:** - [ ] Documentation - [ ] Minium required manager version - [ ] Specific setting for review (eg., KB link, endpoint or how to setup) - [x] Minimum requirements to check during review - [x] Test case(s) to demonstrate the difference of before/after ## Stack Story 3 of Epic FR-2616. See [dev plan](../blob/main/.specs/draft-stoken-login-boundary/dev-plan.md) for the full story breakdown. [FR-2627]: https://lablup.atlassian.net/browse/FR-2627 [FR-2616]: https://lablup.atlassian.net/browse/FR-2616
abeb16c to
d650bff
Compare
87f643c to
547b702
Compare
…6865) Resolves FR-2639 and FR-2643 (under Stories [FR-2626](https://lablup.atlassian.net/browse/FR-2626) / [FR-2627](https://lablup.atlassian.net/browse/FR-2627), Epic [FR-2616](https://lablup.atlassian.net/browse/FR-2616)) resolves #NNN (FR-MMM) <!-- replace NNN, MMM with the GitHub issue number and the corresponding Jira issue number. --> <!-- Please precisely, concisely, and concretely describe what this PR changes, the rationale behind codes, and how it affects the users and other developers. --> **Checklist:** (if applicable) - [ ] Documentation - [ ] Minium required manager version - [ ] Specific setting for review (eg., KB link, endpoint or how to setup) - [ ] Minimum requirements to check during review - [ ] Test case(s) to demonstrate the difference of before/after ## Stack Story 2/3 E2E regression for Epic FR-2616. Sits on top of the Story 2 (#6861) and Story 3 (#6864) implementation PRs. [FR-2626]: https://lablup.atlassian.net/browse/FR-2626?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [FR-2627]: https://lablup.atlassian.net/browse/FR-2627?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [FR-2616]: https://lablup.atlassian.net/browse/FR-2616?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
d650bff to
d7fb3b2
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Resolves FR-2639 and FR-2643 (under Stories FR-2626 / FR-2627, Epic FR-2616)
resolves #NNN (FR-MMM)
Checklist: (if applicable)
Stack
Story 2/3 E2E regression for Epic FR-2616. Sits on top of the Story 2 (#6861) and Story 3 (#6864) implementation PRs.