Hello, thanks for making this plugins. It really helps me a lot to test social login.
Just one thing is that I have type error here.
I looked up a lot, and still haven't figured out how to do it.
Error message
No overload matches this call.
The last overload gave the following error.
Argument of type '({ cookies }: { cookies: cookieType[]; }) => void' is not assignable to parameter of type '(this: ObjectLike, currentSubject: unknown) => void'.
Types of parameters '__0' and 'currentSubject' are incompatible.
Type 'unknown' is not assignable to type '{ cookies: cookieType[]; }'.
Hello, thanks for making this plugins. It really helps me a lot to test social login. Just one thing is that I have type error here. I looked up a lot, and still haven't figured out how to do it.
Error message
No overload matches this call. The last overload gave the following error. Argument of type '({ cookies }: { cookies: cookieType[]; }) => void' is not assignable to parameter of type '(this: ObjectLike, currentSubject: unknown) => void'. Types of parameters '__0' and 'currentSubject' are incompatible. Type 'unknown' is not assignable to type '{ cookies: cookieType[]; }'.
my codes
[auth.cy.ts]
import * as dotenv from 'dotenv'; import path from 'path';
const { GoogleSocialLogin } = require('cypress-social-logins').plugins;
dotenv.config({ path: path.resolve(process.cwd(), '.vercel', '.env.development.local'), });
export default defineConfig({ viewportWidth: 1280, viewportHeight: 800, env: { /**
Delete yout account before push */ testUser: { email: '' || process.env.TEST_USER_ID, password: '' || process.env.TEST_USER_PW, }, apiUrl: process.env.NEXT_PUBLIC_API_SERVER_URL, }, component: { devServer: { framework: 'next', bundler: 'webpack', }, },
watchForFileChanges: false,
clientCertificates: [ { url: 'https://voicelab-local.lovo.ai', ca: [], certs: [ { cert: 'nginx/voicelab-local.lovo.ai.pem', key: 'nginx/voicelab-local.lovo.ai-key.pem', }, ], }, ], e2e: { baseUrl: 'https://voicelab-local.lovo.ai', defaultCommandTimeout: 10000, setupNodeEvents(on) { on('task', { GoogleSocialLogin, }); }, }, });