Fix test setup
This commit is contained in:
parent
1bc2c18167
commit
d700b5f145
@ -1,5 +1,6 @@
|
|||||||
import { calcDifficultyAdjustment, DifficultyAdjustment } from '../../api/difficulty-adjustment';
|
import { calcDifficultyAdjustment, DifficultyAdjustment } from '../../api/difficulty-adjustment';
|
||||||
|
|
||||||
|
describe('Mempool Difficulty Adjustment', () => {
|
||||||
test('should calculate Difficulty Adjustments properly', () => {
|
test('should calculate Difficulty Adjustments properly', () => {
|
||||||
const dt = (dtString) => {
|
const dt = (dtString) => {
|
||||||
return Math.floor(new Date(dtString).getTime() / 1000);
|
return Math.floor(new Date(dtString).getTime() / 1000);
|
||||||
@ -58,3 +59,4 @@ test('should calculate Difficulty Adjustments properly', () => {
|
|||||||
expect(result).toStrictEqual(vector[1]);
|
expect(result).toStrictEqual(vector[1]);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
});
|
||||||
|
@ -1 +1,5 @@
|
|||||||
jest.mock('./mempool-config.json', () => ({}), { virtual: true });
|
jest.mock('./mempool-config.json', () => ({}), { virtual: true });
|
||||||
|
jest.mock('./src/logger.ts', () => ({}), { virtual: true });
|
||||||
|
jest.mock('./src/api/rbf-cache.ts', () => ({}), { virtual: true });
|
||||||
|
jest.mock('./src/api/mempool.ts', () => ({}), { virtual: true });
|
||||||
|
jest.mock('./src/api/memory-cache.ts', () => ({}), { virtual: true });
|
||||||
|
Loading…
x
Reference in New Issue
Block a user