test(claude): cover remove-nonexistent + list live-update for the 95% margin
Two more real branches the account feature left uncovered: removing an unregistered account (the no-such-account error) and the registry list rebuilding when a CLI-side registration notifies the shared settings store. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -140,6 +140,13 @@ void main() {
|
||||
expect(published.single.data, {'action': 'login', 'name': 'work', 'dir': '/home/u/.claude-work'});
|
||||
});
|
||||
|
||||
test('remove of an unregistered account → no-such-account error', () async {
|
||||
wire();
|
||||
final r = await run(['remove', 'ghost']);
|
||||
expect(r.ok, isFalse);
|
||||
expect(r.error?.message, contains('no such account'));
|
||||
});
|
||||
|
||||
test('set/unset with no workspace open error clearly', () async {
|
||||
wire(cwd: null);
|
||||
final set = await run(['set', 'work']);
|
||||
|
||||
Reference in New Issue
Block a user