提交
This commit is contained in:
1 parent
d08f03ab03
commit
cc843535f5
154 files changed
+17837
-5153
No files matched your search
@@ -0,0 +1,9 @@
|
||||
import assert from 'node:assert/strict'
|
||||
import test from 'node:test'
|
||||
|
||||
import { createHttpError } from './http.js'
|
||||
|
||||
test('preserves HTTP or response envelope status for non-leaking market errors', () => {
|
||||
assert.equal(createHttpError({ code: 403, message: '禁止' }, 200).status, 403)
|
||||
assert.equal(createHttpError({ detail: 'missing' }, 404).status, 404)
|
||||
})
|
||||
Reference in new issue
Block a user