Open lfontana-schema31 opened 5 years ago
This doesn't work. promise is pending and it will not be resolved :(
promise
interface ITest { f(): Promise<ITest>; } describe('test suite', () => { it('test', async () => { const mockedObj = m.mock<ITest>(); m.when(mockedObj.f()).thenResolve(mockedObj); const istance = m.instance(mockedObj); const promise = istance.f(); const res = await promise; expect(res).to.equal(mockedObj); }); });
Thanks for reporting. I will take a look
This doesn't work.
promise
is pending and it will not be resolved :(