fix test typings

This commit is contained in:
dswbx
2025-03-11 09:38:14 +01:00
parent eb451a8e1a
commit 0dd29c3b07
4 changed files with 19 additions and 13 deletions

View File

@@ -7,8 +7,8 @@ describe("OAuthStrategy", async () => {
const strategy = new OAuthStrategy({
type: "oidc",
client: {
client_id: process.env.OAUTH_CLIENT_ID,
client_secret: process.env.OAUTH_CLIENT_SECRET,
client_id: process.env.OAUTH_CLIENT_ID!,
client_secret: process.env.OAUTH_CLIENT_SECRET!,
},
name: "google",
});
@@ -19,11 +19,6 @@ describe("OAuthStrategy", async () => {
const config = await strategy.getConfig();
console.log("config", JSON.stringify(config, null, 2));
const request = await strategy.request({
redirect_uri,
state,
});
const server = Bun.serve({
fetch: async (req) => {
const url = new URL(req.url);
@@ -39,6 +34,11 @@ describe("OAuthStrategy", async () => {
return new Response("Bun!");
},
});
const request = await strategy.request({
redirect_uri,
state,
});
console.log("request", request);
await new Promise((resolve) => setTimeout(resolve, 100000));