Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
},
"devDependencies": {
"@testing-library/react-native": "^12.4.3",
"@types/jest": "^29.5.12",
"@types/jest": "^30.0.0",
"@types/react": "^19.0.0",
"@types/react-native": "^0.73.0",
"@typescript-eslint/eslint-plugin": "^7.9.0",
Expand All @@ -59,7 +59,7 @@
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-react": "^7.34.1",
"eslint-plugin-react-hooks": "^4.6.0",
"jest": "^29.7.0",
"jest": "^30.0.0",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🌐 Web query:

What are the minimum Node.js and TypeScript version requirements for Jest version 30?

💡 Result:

Minimum Node.js version requirement for Jest 30: Node.js 18.x (support for Node 14, 16, 19, and 21 was dropped). [1][2] Minimum TypeScript version requirement for Jest 30: TypeScript 5.4. [1][2] These requirements are stated in Jest’s official “Upgrading to Jest 30” documentation and the Jest 30 release blog post. [1][2]

Citations:


🏁 Script executed:

#!/bin/bash
# Description: Run the test suite to verify Jest v30 compatibility

# Run tests in the current configuration
npm test 2>&1 | head -50

Repository: ZeroGachis/smartway-react-native-ui

Length of output: 161


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Inspect package.json around the declared Jest dependency
ls -la
test -f package.json && sed -n '1,120p' package.json

# Locate Jest config entrypoints if present
for f in jest.config.ts jest.config.js jest.config.cjs; do
  if [ -f "$f" ]; then echo "---- $f ----"; sed -n '1,200p' "$f"; fi
done

# Show package.json scripts to see how `npm test` invokes Jest
node -e "const p=require('./package.json'); console.log(p.scripts)"

Repository: ZeroGachis/smartway-react-native-ui

Length of output: 4754


🏁 Script executed:

npm ci && npm test

Repository: ZeroGachis/smartway-react-native-ui

Length of output: 31592


Fix Jest 30 upgrade prerequisites (Node/TypeScript) and make dependencies/install reproducible

Jest 30 requires Node.js 18.x and TypeScript >= 5.4, but this repo uses TypeScript ^5.2.2 and ts-jest ^29.1.0 (Jest 29 era). Also, tests can’t be run cleanly because npm ci fails due to package-lock.json being out of sync with the Jest 30 dependency (lockfile still contains Jest 29.x), and npm test fails with “jest: not found”. Update TypeScript (>=5.4), bump ts-jest to a Jest-30-compatible version, and regenerate package-lock.json (then run npm test).

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@package.json` at line 62, package.json currently pins "jest" to ^30.0.0 but
still lists incompatible tooling—update "typescript" to >=5.4 (e.g. ^5.4.0) and
bump "ts-jest" to a Jest-30-compatible release, and if you declare an engines
field ensure Node >=18 is specified; after updating the dependency entries
("typescript", "ts-jest", and optionally "engines") delete and regenerate
package-lock.json by running npm ci / npm install to produce a lockfile
consistent with Jest 30, then run npm test to verify jest is found and tests
pass.

"jest-junit": "^15.0.0",
"prettier": "3.2.5",
"prettier-eslint": "^16.3.0",
Expand Down
Loading