refactor(data): describe tile budgets per period, drop a duplicate test, add the changelog entry

This commit is contained in:
German Khokhlov committed 2026-11-09 19:41:51 +04:00
1 parent 4e40594d4f
commit 75e8e7ddbd
4 files changed
+18 -29

No files matched your search

-16
View File
@@ -8,19 +8,3 @@ test('tile budget helpers live in one module and TomTom re-exports them', () =>
assert.equal(tomtom.normalizeBudget, normalizeBudget);
assert.equal(tomtom.isOverBudget, isOverBudget);
});
test('normalizeBudget keeps a valid state and resets another period', () => {
const state = { date: '2026-09-24', count: 3 };
assert.equal(normalizeBudget(state, '2026-09-24'), state);
assert.deepEqual(normalizeBudget(state, '2026-09-25'), {
date: '2026-09-25',
count: 0,
});
assert.deepEqual(
normalizeBudget({ date: '2026-09-24', count: -1 }, '2026-09-24'),
{
date: '2026-09-24',
count: 0,
},
);
});