start of store unit tests

This commit is contained in:
Katie Kroell 2023-10-17 12:47:09 -04:00
parent dac7637bdf
commit e23645eb02

View file

@ -1104,4 +1104,22 @@ describe('Store', () => {
expect(store.isDropOffAppointment).toBe(false);
});
});
describe('getFinalDeductible method', () => {
describe('successful method call', () => {
it.only('calls get final deductible api endpoint', () => {
// Arrange
globalMethods.callHttpClient = jest.fn().mockReturnValue(Promise.resolve({}));
// Act
store.getFinalDeductible();
// Assert
expect(globalMethods.callHttpClient).toHaveBeenCalledWith(expect.objectContaining({
method: endpoints.FinalDeductible.method,
endpoint: endpoints.FinalDeductible.url,
}));
});
});
});
});