Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
N
node-json-parse-better-errors
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Debian JavaScript Maintainers
node-json-parse-better-errors
Commits
b8c94ab3
Commit
b8c94ab3
authored
3 years ago
by
Yadd
Browse files
Options
Downloads
Patches
Plain Diff
Fix test for tap >= 15
Closes: #1009554
parent
f668cf58
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
debian/patches/fix-for-tap-15.patch
+87
-0
87 additions, 0 deletions
debian/patches/fix-for-tap-15.patch
debian/patches/series
+1
-0
1 addition, 0 deletions
debian/patches/series
with
88 additions
and
0 deletions
debian/patches/fix-for-tap-15.patch
0 → 100644
+
87
−
0
View file @
b8c94ab3
Description: fix for tap >= 15
Author: Yadd <yadd@debian.org>
Bug-Debian: https://bugs.debian.org/1009554
Forwarded: no
Last-Update: 2022-04-13
--- a/test/index.js
+++ b/test/index.js
@@ -12,7 +12,7 @@
}
})
t.deepEqual(JSON.parse(data), parseJson(data), 'does the same thing')
- t.done()
+ t.end()
})
test('throws SyntaxError for unexpected token', t => {
@@ -21,7 +21,7 @@
() => parseJson(data),
new SyntaxError('Unexpected token o in JSON at position 1 while parsing near \'foo\'')
)
- t.done()
+ t.end()
})
test('throws SyntaxError for unexpected end of JSON', t => {
@@ -30,7 +30,7 @@
() => parseJson(data),
new SyntaxError('Unexpected end of JSON input while parsing near \'{"foo: bar}\'')
)
- t.done()
+ t.end()
})
test('throws SyntaxError for unexpected number', t => {
@@ -39,7 +39,7 @@
() => parseJson(data),
new SyntaxError('Unexpected number in JSON at position 8')
)
- t.done()
+ t.end()
})
test('SyntaxError with less context (limited start)', t => {
@@ -47,7 +47,7 @@
t.throws(
() => parseJson(data, null, 3),
new SyntaxError('Unexpected end of JSON input while parsing near \'...3210\''))
- t.done()
+ t.end()
})
test('SyntaxError with less context (limited end)', t => {
@@ -55,7 +55,7 @@
t.throws(
() => parseJson(data, null, 2),
new SyntaxError('Unexpected token a in JSON at position 0 while parsing near \'ab...\''))
- t.done()
+ t.end()
})
test('throws TypeError for undefined', t => {
@@ -63,7 +63,7 @@
() => parseJson(undefined),
new TypeError('Cannot parse undefined')
)
- t.done()
+ t.end()
})
test('throws TypeError for non-strings', t => {
@@ -71,7 +71,7 @@
() => parseJson(new Map()),
new TypeError('Cannot parse [object Map]')
)
- t.done()
+ t.end()
})
test('throws TypeError for empty arrays', t => {
@@ -79,5 +79,5 @@
() => parseJson([]),
new TypeError('Cannot parse an empty array')
)
- t.done()
+ t.end()
})
This diff is collapsed.
Click to expand it.
debian/patches/series
0 → 100644
+
1
−
0
View file @
b8c94ab3
fix-for-tap-15.patch
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment