mirror of
https://github.com/shishantbiswas/bknd.git
synced 2026-03-15 20:17:22 +00:00
* refactored adapters to run test suites * fix bun version for tests * added missing adapter tests and refactored examples to use `bknd.config.ts` where applicable
16 lines
539 B
TypeScript
16 lines
539 B
TypeScript
import { afterAll, beforeAll, describe } from "bun:test";
|
|
import * as astro from "./astro.adapter";
|
|
import { disableConsoleLog, enableConsoleLog } from "core/utils";
|
|
import { adapterTestSuite } from "adapter/adapter-test-suite";
|
|
import { bunTestRunner } from "adapter/bun/test";
|
|
|
|
beforeAll(disableConsoleLog);
|
|
afterAll(enableConsoleLog);
|
|
|
|
describe("astro adapter", () => {
|
|
adapterTestSuite(bunTestRunner, {
|
|
makeApp: astro.getApp,
|
|
makeHandler: (c, a, o) => (request: Request) => astro.serve(c, a, o)({ request }),
|
|
});
|
|
});
|