[PR #59] [MERGED] Fix timestamp test suite #2994

Closed
opened 2026-02-28 20:34:45 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/actualbudget/actual/pull/59
Author: @TomAFrench
Created: 5/9/2022
Status: Merged
Merged: 6/29/2022
Merged by: @jlongster

Base: masterHead: timestamp-test-suite-fix


📝 Commits (4)

  • 98b0761 test: fix test to properly pass in invalid inputs individually
  • 06baf96 fix: enforce proper length constraints on timestamp counter and node id
  • d3381c1 style: replace var with const
  • b89d7cb style: revert to using var to minimise diff

📊 Changes

2 files changed (+21 additions, -10 deletions)

View changed files

📝 packages/loot-core/src/server/timestamp.js (+14 -3)
📝 packages/loot-core/src/server/timestamp.test.js (+7 -7)

📄 Description

I noticed an issue in the timestamp test suite where we're passing the full array of invalid inputs into Timestamp.parse rather than one by one. Fixing this shows that we're accepting a number of invalid timestamp formats so I've added additional checks on this.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/actualbudget/actual/pull/59 **Author:** [@TomAFrench](https://github.com/TomAFrench) **Created:** 5/9/2022 **Status:** ✅ Merged **Merged:** 6/29/2022 **Merged by:** [@jlongster](https://github.com/jlongster) **Base:** `master` ← **Head:** `timestamp-test-suite-fix` --- ### 📝 Commits (4) - [`98b0761`](https://github.com/actualbudget/actual/commit/98b0761353d8a775e4e30f66b2b2b542b9d20dc3) test: fix test to properly pass in invalid inputs individually - [`06baf96`](https://github.com/actualbudget/actual/commit/06baf963dde53fe10b063502bff80333db18ed9d) fix: enforce proper length constraints on timestamp counter and node id - [`d3381c1`](https://github.com/actualbudget/actual/commit/d3381c17d26796bde629d0f946fcc49a26a4dd0c) style: replace var with const - [`b89d7cb`](https://github.com/actualbudget/actual/commit/b89d7cb7922a3d0f4ad8856e24b4050c8ab337b2) style: revert to using var to minimise diff ### 📊 Changes **2 files changed** (+21 additions, -10 deletions) <details> <summary>View changed files</summary> 📝 `packages/loot-core/src/server/timestamp.js` (+14 -3) 📝 `packages/loot-core/src/server/timestamp.test.js` (+7 -7) </details> ### 📄 Description I noticed an issue in the timestamp test suite where we're passing the full array of invalid inputs into `Timestamp.parse` rather than one by one. Fixing this shows that we're accepting a number of invalid timestamp formats so I've added additional checks on this. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-02-28 20:34:45 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#2994