ServiceMock
Home > @backstage/backend-test-utils
> ServiceMock
Signature:
export type ServiceMock<TService> = {
factory: ServiceFactory<TService>;
} & {
[Key in keyof TService]: TService[Key] extends (...args: infer Args) => infer Return ? TService[Key] & jest.MockInstance<Return, Args> : TService[Key];
};
References: ServiceFactory