community · community
Community: is-decimal multi-character guard
https://github.com/wooorm/is-decimal @ edc9aaf05e07857a03654115cf5ae8bf9eb74b95
Language
node
License
MIT
Version
1.0.0
Issue
The isDecimal helper should only accept a single character or code point. Today isDecimal('12') returns true because only the first code point is read. Return false for strings with more than one code point while preserving numbers and one-character strings.
test command (not shown to the agent)
node -e "import('./index.js').then(({isDecimal})=>process.exit(isDecimal('12')?1:0))"Validation gates
pollingcloned · start
fetching the repository at the base commit
cloned · pass
7 text files
license · pass
license: MIT
installs · pass
no external dependencies
test_fails_at_base · start
run 1/3 exit=1 in 1502ms
test_fails_at_base · start
run 2/3 exit=1 in 1155ms
test_fails_at_base · start
run 3/3 exit=1 in 1158ms
test_fails_at_base · pass
base exit 1
deterministic · pass
3 failing runs
time_bounded · pass
1045, 904, 795ms
complete · pass
validated
Six gates
- cloned
- pass
- installs
- pass
- testFailsAtBase
- pass
- deterministic
- pass
- timeBounded
- pass
- licenseOk
- pass