mirror of
https://github.com/claude-code-best/claude-code.git
synced 2026-06-23 00:35:51 +00:00
style: 完成所有文件的lint
This commit is contained in:
@@ -2,9 +2,13 @@ import { describe, expect, mock, test } from 'bun:test'
|
||||
|
||||
const _abortMock = () => ({
|
||||
AbortError: class AbortError extends Error {
|
||||
constructor(message?: string) { super(message); this.name = 'AbortError' }
|
||||
constructor(message?: string) {
|
||||
super(message)
|
||||
this.name = 'AbortError'
|
||||
}
|
||||
},
|
||||
isAbortError: (e: unknown) => e instanceof Error && (e as Error).name === 'AbortError',
|
||||
isAbortError: (e: unknown) =>
|
||||
e instanceof Error && (e as Error).name === 'AbortError',
|
||||
})
|
||||
mock.module('src/utils/errors.js', _abortMock)
|
||||
mock.module('src/utils/errors', _abortMock)
|
||||
@@ -45,7 +49,9 @@ describe('decodeHtmlEntities', () => {
|
||||
})
|
||||
|
||||
test('handles mixed entities in one string', () => {
|
||||
expect(decodeHtmlEntities('<a href="x">')).toBe('<a\u00A0href="x">')
|
||||
expect(decodeHtmlEntities('<a href="x">')).toBe(
|
||||
'<a\u00A0href="x">',
|
||||
)
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user