草庐IT

specificMockImpl

全部标签

javascript - JEST 错误 TypeError : specificMockImpl. apply is not a function

尝试使用来自api的回调来模拟其中一个函数并得到错误TypeError:specificMockImpl.applyisnotafunctionimport{IEnvironmentMap,load}from'dotenv-extended';import{getTokensWithAuthCode,sdk}from'../src/connection-manager';describe('getTokensWithAuthCodefunctionTests',()=>{jest.useFakeTimers();letboxConfig:IEnvironmentMap;beforeAl