Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,9 @@ jobs:
os: windows-latest
shell: cmd
node-version:
- 10.0.0
- 10.x
- 12.x
- 14.x
- 16.x
- 18.x
- 20.x
- 22.x
- 24.x
exclude:
- platform: { name: macOS, os: macos-latest, shell: bash }
node-version: 10.0.0
Expand Down
4 changes: 3 additions & 1 deletion internal/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@
const SEMVER_SPEC_VERSION = '2.0.0'

const MAX_LENGTH = 256
/* node:coverage disable */
const MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER ||
/* istanbul ignore next */ 9007199254740991
9007199254740991
/* node:coverage enable */

// Max safe segment length for coercion.
const MAX_SAFE_COMPONENT_LENGTH = 16
Expand Down
16 changes: 4 additions & 12 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"description": "The semantic version parser used by npm.",
"main": "index.js",
"scripts": {
"test": "tap",
"snap": "tap",
"test": "node --test --experimental-test-coverage --test-timeout=3000 --test-coverage-lines=100 --test-coverage-functions=100 --test-coverage-branches=100",
"snap": "node --test --test-update-snapshots",
"lint": "npm run eslint",
"postlint": "template-oss-check",
"lintfix": "npm run eslint -- --fix",
Expand All @@ -16,8 +16,7 @@
"devDependencies": {
"@npmcli/eslint-config": "^5.0.0",
"@npmcli/template-oss": "4.25.1",
"benchmark": "^2.1.4",
"tap": "^16.0.0"
"benchmark": "^2.1.4"
},
"license": "ISC",
"repository": {
Expand All @@ -35,17 +34,10 @@
"internal/",
"ranges/",
"index.js",
"map.js",
"preload.js",
"range.bnf"
],
"tap": {
"timeout": 30,
"coverage-map": "map.js",
"nyc-arg": [
"--exclude",
"tap-snapshots/**"
]
},
"engines": {
"node": ">=10"
},
Expand Down
2 changes: 1 addition & 1 deletion ranges/min-version.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ const minVersion = (range, loose) => {
case '<=':
/* Ignore maximum versions */
break
/* istanbul ignore next */
/* node:coverage ignore next 2 */
default:
throw new Error(`Unexpected operation: ${comparator.operator}`)
}
Expand Down
Loading
Loading