Last active
September 18, 2018 21:11
-
-
Save leongaban/aebdd8b570658be0ddf3b396c1eaaf4a to your computer and use it in GitHub Desktop.
poolTest
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import LiquidityPoolApi from './LiquidityPool'; | |
const endpoint = '/frontoffice/api/liquidity-pool/get-total-payout'; | |
jest.mock(endpoint, () => ({ | |
getUsersTotalPayout: jest.fn(() => Promise.resolve({ data: { payout: 100.21 } })) | |
})); | |
describe('LiquidityPool API: getUsersTotalPayout', () => { | |
it('should make a request when we get images', () => { | |
// const testApi = new LiquidityPoolApi(); | |
expect(LiquidityPoolApi.getUsersTotalPayout).toHaveBeenCalledWith(endpoint, 'GET'); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment