Skip to content

test: convert throw statements to expect() - #643

Merged
colincasey merged 2 commits into
masterfrom
wjh/test-cleanup
Nov 19, 2026
Merged

colincasey merged 2 commits into
masterfrom
wjh/test-cleanup

Conversation

@wjhsf

@wjhsf wjhsf commented Sep 22, 2026

Copy link
Copy Markdown
Contributor

Just looks nicer in tests...

Comment thread lib/__tests__/cookieJar.spec.ts Resolved
Comment thread lib/cookie/cookieJar.ts Resolved
Comment thread lib/cookie/cookieJar.ts Resolved
Comment thread lib/__tests__/sameSite.spec.ts Resolved
Comment thread lib/__tests__/cookieJar.spec.ts Resolved
@colincasey colincasey added this to the v6 milestone Oct 15, 2026
wjhsf and others added 2 commits November 19, 2026 16:16
Replace `expect(x).toBeDefined()` followed by `x!` or `x?.` with
`assert.exists(x)` / `assert.instanceOf(x, Cookie)` so the type is
narrowed and the `no-non-null-assertion` disables can be removed.
@colincasey
colincasey merged commit e50cb72 into master Nov 19, 2026
10 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants