Refactor Store.storeHistory tests to exercise the method directly#7
Conversation
Co-authored-by: Samuel3 <15921086+Samuel3@users.noreply.github.com>
|
@copilot please fix build |
Co-authored-by: Samuel3 <15921086+Samuel3@users.noreply.github.com>
|
@copilot fix merge conflict with package-lock.json |
There was a problem hiding this comment.
Pull request overview
This PR aims to refactor the Store.storeHistory unit tests to invoke storeHistory directly (instead of manually manipulating history), and it also touches dependency lockfiles related to an npm ci CI failure.
Changes:
- Refactored
Store.storeHistorytests to set up history state and callstore.storeHistory(...)directly. - Updated
app/package-lock.jsoncontents (including changinglockfileVersionto 3 and converting to the npm v7+ “packages” format).
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
test/store.test.js |
Simplifies Store.storeHistory tests by calling storeHistory directly and asserting resulting history state. |
app/package-lock.json |
Large lockfile rewrite to npm lockfile v3 format (lockfileVersion: 3, packages section). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…nflict Co-authored-by: Samuel3 <15921086+Samuel3@users.noreply.github.com>
Fixed in commit |
…ined branch test Co-authored-by: Samuel3 <15921086+Samuel3@users.noreply.github.com>
|
@copilot please fix issue with conflict of app/package-lock.json |
Co-authored-by: Samuel3 <15921086+Samuel3@users.noreply.github.com>
Fixed in commit |
Refactors the
Store.storeHistoryunit tests to callstoreHistorydirectly instead of manually manipulating history, and syncsapp/package-lock.jsonwith thefeature/add-testsbase branch to resolve the merge conflict.Changes Made
Store.storeHistorytests: Tests now set up initial history state and callstore.storeHistory(...)directly, asserting the resulting history.history === undefinedinitialization branch inStore.prototype.storeHistory, using aglobal.getCurrentContentmock to exercise first-run behavior.app/package-lock.json: Updated to exactly match thefeature/add-testsbase branch (lockfileVersion 3,packagesformat) to eliminate the merge conflict and ensurenpm ciis deterministic.Testing
npm cisucceeds with synced lockfileshistory === undefinedbranch)💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.