fix: correct login() return value documentation in CLAUDE.md
- Fix return value from 2-tuple to 4-tuple (browser, context, page, main_frame) - Correct function signature to match actual implementation - Documentation now matches the actual API Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -40,10 +40,10 @@ Note: Test scripts are responsible for loading environment variables and passing
|
|||||||
### Module Structure
|
### Module Structure
|
||||||
|
|
||||||
**`utils/auth.py`** - Core authentication module (pure functions)
|
**`utils/auth.py`** - Core authentication module (pure functions)
|
||||||
- `login(url, username, password, page)` - Handles Yonyou BIP login with automatic force-login popup detection. Requires all parameters explicitly.
|
- `login(playwright, username, password, url, headless, ignore_https_errors, verbose=True)` - Handles Yonyou BIP login with automatic force-login popup detection. Requires all parameters (playwright, username, password, url, headless, ignore_https_errors).
|
||||||
- `logout(page)` - Performs logout with confirmation dialog handling
|
- `logout(page)` - Performs logout with confirmation dialog handling.
|
||||||
- Callers are responsible for browser lifecycle management (context.close(), browser.close())
|
- Returns tuple: `(browser, context, page, main_frame)` where `main_frame` is the forwardFrame iframe.
|
||||||
- Returns tuple: `(page, main_frame)` where `main_frame` is the forwardFrame iframe
|
- Callers are responsible for browser lifecycle management (context.close(), browser.close()).
|
||||||
|
|
||||||
**`tests/`** - Test suite
|
**`tests/`** - Test suite
|
||||||
- All test files must add `PROJECT_ROOT` to `sys.path` to import `utils` modules
|
- All test files must add `PROJECT_ROOT` to `sys.path` to import `utils` modules
|
||||||
|
|||||||
Reference in New Issue
Block a user