Merge branch 'main' into next

This commit is contained in:
saltyaom
2025-12-28 23:14:48 +07:00
2 changed files with 24 additions and 2 deletions
+2 -2
View File
@@ -617,7 +617,7 @@ export const isContextPassToFunction = (
}
}
let pendingGC: number | undefined
let pendingGC: Timer | undefined
let caches = <Record<number, Sucrose.Inference>>{}
export const clearSucroseCache = (delay: Sucrose.Settings['gcTime']) => {
@@ -632,7 +632,7 @@ export const clearSucroseCache = (delay: Sucrose.Settings['gcTime']) => {
pendingGC = undefined
if (isBun) Bun.gc(false)
}, delay) as unknown as number
}, delay).unref()
}
export const mergeInference = (a: Sucrose.Inference, b: Sucrose.Inference) => {
+22
View File
@@ -0,0 +1,22 @@
import { describe, expect, it } from 'bun:test'
describe('Integration', () => {
it(
'Allows process to finish',
async () => {
const res = Bun.spawn({
cmd: [
'bun',
'-e',
"import { Elysia } from './src'; new Elysia().onBeforeHandle(() => { });"
]
})
const status = await res.exited;
expect(status).toEqual(0);
},
{
timeout: 500
}
)
})