mirror of
https://github.com/status-im/MyCrypto.git
synced 2025-01-18 23:22:07 +00:00
c76d0b3fa5
* Give each network the ability to specify default estimates, and whether or not they should fetch estimates from API. Convert gas slider to always use estimates. * Fix gas cache invalidation, invalid too high / low logic. * Fix up tests. * tscheck
18 lines
620 B
TypeScript
18 lines
620 B
TypeScript
import { INITIAL_STATE, staticNetworks } from 'reducers/config/networks/staticNetworks';
|
|
|
|
describe('Testing contained data', () => {
|
|
it(`contain unique chainIds`, () => {
|
|
const networkValues = Object.values(INITIAL_STATE);
|
|
const chainIds = networkValues.map(a => a.chainId);
|
|
const chainIdsSet = new Set(chainIds);
|
|
expect(Array.from(chainIdsSet).length).toEqual(chainIds.length);
|
|
});
|
|
});
|
|
|
|
describe('static networks reducer', () => {
|
|
it('should return the initial state', () =>
|
|
expect(JSON.stringify(staticNetworks(undefined, {} as any))).toEqual(
|
|
JSON.stringify(INITIAL_STATE)
|
|
));
|
|
});
|