Repository navigation
Commit 723c363
committed
test(webview): pin zoo-gateway seeding to every-profile semantics
The review thread on the seeding suite measured true against 45795c8: every seeding case
put a single zoo-gateway profile in the store, where a first-only check, a last-only check,
an every-profile check and the shipped any-profile guard all take the same branch, and the
case titled "...stale or missing token" never left zooSessionToken unset.
Added three cases, with the production guard untouched. Two run through it.each over a store
of ["Zoo Gateway", "Other", "Zoo Gateway 2"] where "Other" is an anthropic profile: one with
the stale profile last, one with it first; each asserts handleZooCodeCallback ran with the
fresh token and that getProfile was never asked about "Other", which is what exercises the
apiProvider filter. The third gives a zoo-gateway profile with a current base URL and no
token at all, and asserts seeding still runs.
Controls, each applied to src/core/webview/ClineProvider.ts, measured, then reverted (the
file's blob is ee8203a before and after, and git checkout HEAD -- confirmed it):
zooGatewayProfiles.slice(0, 1) fails the stale-last case; .slice(-1) fails the stale-first
case; replacing the apiProvider filter with () => true fails the "Other" assertion in the
stale-last row; requiring a non-null token before comparing fails the no-token case. Every
mutation kills exactly one test and nothing else.
vitest core/webview + core/config: 44 files / 1299 tests green (1296 before this commit, plus
the three new cases). prettier --check, tsc --noEmit -p . and eslint --max-warnings=0 are
clean; scope unchanged at 810 extension-package executable lines (no production change).1 parent 45795c8 commit 723c363
1 file changed
Lines changed: 67 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9785 | 9785 | | |
9786 | 9786 | | |
9787 | 9787 | | |
| 9788 | + | |
| 9789 | + | |
| 9790 | + | |
| 9791 | + | |
| 9792 | + | |
| 9793 | + | |
| 9794 | + | |
| 9795 | + | |
| 9796 | + | |
| 9797 | + | |
| 9798 | + | |
| 9799 | + | |
| 9800 | + | |
| 9801 | + | |
| 9802 | + | |
| 9803 | + | |
| 9804 | + | |
| 9805 | + | |
| 9806 | + | |
| 9807 | + | |
| 9808 | + | |
| 9809 | + | |
| 9810 | + | |
| 9811 | + | |
| 9812 | + | |
| 9813 | + | |
| 9814 | + | |
| 9815 | + | |
| 9816 | + | |
| 9817 | + | |
| 9818 | + | |
| 9819 | + | |
| 9820 | + | |
| 9821 | + | |
| 9822 | + | |
| 9823 | + | |
| 9824 | + | |
| 9825 | + | |
| 9826 | + | |
| 9827 | + | |
| 9828 | + | |
| 9829 | + | |
| 9830 | + | |
| 9831 | + | |
| 9832 | + | |
| 9833 | + | |
| 9834 | + | |
| 9835 | + | |
| 9836 | + | |
| 9837 | + | |
| 9838 | + | |
| 9839 | + | |
| 9840 | + | |
| 9841 | + | |
| 9842 | + | |
| 9843 | + | |
| 9844 | + | |
| 9845 | + | |
| 9846 | + | |
| 9847 | + | |
| 9848 | + | |
| 9849 | + | |
| 9850 | + | |
| 9851 | + | |
| 9852 | + | |
| 9853 | + | |
| 9854 | + | |
9788 | 9855 | | |
9789 | 9856 | | |
9790 | 9857 | | |
0 commit comments