server.test.ts
This file
Path
adapters/bun/src/server.test.ts
18 lines 路 508 bytes 路 TypeScript
Last changed by
feat(adapters): add @hono/bun as a workspace package (#5447)Yusuke Wadabefore adoptionfc2343d
History of this fileTake it
12345678910111213141516171819import { describe, expect, it } from 'bun:test'import { Context } from 'hono'import { getBunServer } from './server'
describe('getBunServer', () => { it('Should success to pick Server', () => { const server = {}
expect( getBunServer<typeof server>(new Context(new Request('http://localhost/'), { env: server })) ).toBe(server) expect( getBunServer<typeof server>( new Context(new Request('http://localhost/'), { env: { server } }) ) ).toBe(server) })})