[Pkg-javascript-commits] [node-stack-utils] 44/67: Add assertion for function names containing spaces

Bastien Roucariès rouca at moszumanska.debian.org
Thu Sep 7 09:53:04 UTC 2017


This is an automated email from the git hooks/post-receive script.

rouca pushed a commit to branch master
in repository node-stack-utils.

commit 93ca7c80827ca66f898cf9da622c89ce3c83670a
Author: Mark Wubben <mark at novemberborn.net>
Date:   Thu Feb 16 14:57:00 2017 +0000

    Add assertion for function names containing spaces
---
 test/test.js | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/test/test.js b/test/test.js
index 23aa57d..a2e7698 100644
--- a/test/test.js
+++ b/test/test.js
@@ -386,6 +386,14 @@ t.test('parseLine', function (t) {
     function: 'SomeClass.someFunc'
   });
 
+  // { "foo bar" () { throw new Error() } }
+  t.same(stack.parseLine('    at Object.foo bar (/user/dev/project/foo.js:3:8)'), {
+    file: 'foo.js',
+    line: 3,
+    column: 8,
+    function: 'Object.foo bar'
+  });
+
   t.same(stack.parseLine('    at foo (/some/other/dir/file.js:3:8)'), {
     file: '/some/other/dir/file.js',
     line: 3,

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-stack-utils.git



More information about the Pkg-javascript-commits mailing list