-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtest-session-debug.ts
More file actions
28 lines (24 loc) · 927 Bytes
/
test-session-debug.ts
File metadata and controls
28 lines (24 loc) · 927 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!/usr/bin/env bun
import { createSessionProvider } from "./src/domain/session/session-db-adapter";
async function testSessionProvider() {
console.log("Testing session provider creation...");
try {
const sessionProvider = await createSessionProvider();
console.log("Session provider created:", typeof sessionProvider);
console.log(
"Available methods:",
Object.getOwnPropertyNames(sessionProvider).filter(
(prop) => typeof sessionProvider[prop] === "function"
)
);
console.log("Has getSession?", typeof sessionProvider.getSession === "function");
if (typeof sessionProvider.getSession === "function") {
console.log("Attempting to call getSession...");
const result = await sessionProvider.getSession("test-session");
console.log("getSession result:", result);
}
} catch (error) {
console.error("Error:", error);
}
}
testSessionProvider();