Fixing test case.

This commit is contained in:
mike12345567 2021-07-23 20:08:16 +01:00
parent cfea184633
commit e76c44000b
1 changed files with 4 additions and 4 deletions

View File

@ -5,7 +5,6 @@ const { data } = require("./utilities/mock-data")
const TENANT_ID = "default"
const googleConfig = {
callbackURL: "http://somecallbackurl",
clientID: data.clientID,
clientSecret: data.clientSecret,
}
@ -28,13 +27,14 @@ describe("google", () => {
it("should create successfully create a google strategy", async () => {
const google = require("../google")
await google.strategyFactory(googleConfig, `/api/global/auth/${TENANT_ID}/google/callback`)
const callbackUrl = `/api/global/auth/${TENANT_ID}/google/callback`
await google.strategyFactory(googleConfig, callbackUrl)
const expectedOptions = {
clientID: googleConfig.clientID,
clientSecret: googleConfig.clientSecret,
callbackURL: googleConfig.callbackURL,
callbackURL: callbackUrl,
}
expect(mockStrategy).toHaveBeenCalledWith(