mozilla / openbadges-backpack

Mozilla Open Badges Backpack
https://backpack.openbadges.org/
Other
862 stars 263 forks source link

npm-5.6.0: `npm test` yields ERR! #1171

Open justineuro opened 5 years ago

justineuro commented 5 years ago

Just tried to create a dev environ using node-5.6.0. npm installwent fine but npm test gave the following ERR message. Thanks in advance for any info you can extend on how to fix this.

$ npm test
> openbadges@3.0.1 test /path/to//BadgeKit/openbadges-backpack
> NODE_ENV=test TAP_TIMEOUT=60000 ./node_modules/.bin/tap-prettify test/*.test.js

✓ FOO CALLED WITH 2 3 function (err, result) {
✓ Subtest: collapseWhitespace() works
✓ time=566.686ms
x Subtest: analyzeAssertion: valid old assertion

  analyzeAssertion: valid old assertion # time=385.22ms failure

x Subtest: analyzeAssertion: invalid old assertion, bad form

  analyzeAssertion: invalid old assertion, bad form # time=97.463ms failure

x Subtest: analyzeAssertion: valid old assertion, url

  analyzeAssertion: valid old assertion, url # time=168.275ms failure

✓ Subtest: analyzeAssertion: url points to nothing
✓ Subtest: analyzeAssertion: bad responses
✓ Subtest: analyzeAssertion: malformed url
x Subtest: analyzeAssertion: new assertion, hosted

  analyzeAssertion: new assertion, hosted # time=240.076ms failure

x Subtest: analyzeAssertion: new assertion, signed

  analyzeAssertion: new assertion, signed # time=447.545ms failure

  Cannot read property 'assertion' of undefined # time=168.275ms failure

  Traceback (most recent call first):
/path/to//BadgeKit/openbadges-backpack/node_modules/tap-prettify/index.js:92
                c.stack.forEach(function(line) {
                        ^

TypeError: c.stack.forEach is not a function
    at /path/to/BadgeKit/openbadges-backpack/node_modules/tap-prettify/index.js:92:25
    at Array.forEach (<anonymous>)
    at TapConsumer.<anonymous> (/path/to/BadgeKit/openbadges-backpack/node_modules/tap-prettify/index.js:78:32)
    at emitOne (events.js:36:792)
    at TapConsumer.emit (events.js:40:172)
    at TapConsumer._parseLine (/path/to/BadgeKit/openbadges-backpack/node_modules/tap-prettify/node_modules/tap/lib/tap-consumer.js:133:20)
    at TapConsumer.write (/path/to/BadgeKit/openbadges-backpack/node_modules/tap-prettify/node_modules/tap/lib/tap-consumer.js:77:10)
    at Runner.ondata (internal/streams/legacy.js:1:7438)
    at emitOne (events.js:36:551)
    at Runner.emit (events.js:40:172)
npm ERR! Test failed.  See above for more details.