refactor: statusbar、companion、herdr 外掛改名加上 jsc- 前綴

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
root
2026-10-13 07:43:50 +00:00
co-authored by Claude Sonnet 5.5
parent f10b168c28
commit 58e2b2d26a
53 changed files with 28 additions and 25 deletions
@@ -0,0 +1,13 @@
import { expect } from 'claude-code/testing'
// 讓只能 import 'claude-code/testing' 的測試沙箱,沿用 node:assert/strict 的寫法
const assert = Object.assign((v: unknown, msg?: string) => expect(v, msg).toBeTruthy(), {
ok: (v: unknown, msg?: string) => expect(v, msg).toBeTruthy(),
equal: (a: unknown, b: unknown, msg?: string) => expect(a, msg).toBe(b),
notEqual: (a: unknown, b: unknown, msg?: string) => expect(a, msg).not.toBe(b),
deepEqual: (a: unknown, b: unknown, msg?: string) => expect(a, msg).toEqual(b),
match: (s: string, re: RegExp, msg?: string) => expect(re.test(s), msg).toBe(true),
doesNotMatch: (s: string, re: RegExp, msg?: string) => expect(re.test(s), msg).toBe(false),
throws: (fn: () => unknown, msg?: string) => expect(fn, msg).toThrow(),
})
export default assert