rddill-IBM / ZeroToBlockchain

Tutorial for Zero to Blockchain series
342 stars 924 forks source link

Chapter 4 : npm run test fails #33

Closed raman2072 closed 6 years ago

raman2072 commented 6 years ago

My buildAndDeploy went fine and smooth. But when I try npm run test it fails with the following error. Can you PLEASE help me out!

1) Finance Network "before all" hook: Error: Failed to load connector module "composer-connector-undefined" for connection type "undefined". Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined'-Cannot find module 'composer-connector-undefined' at Promise.resolve.then (node_modules/composer-common/lib/connectionprofilemanager.js:136:42) at

raman2072 commented 6 years ago

OK, a little bit more persistent research helped me solve this issue.

We need to go to package.json and make sure composer-client, composer-common, composer-admin, composer-playground, composer-rest-server, and composer-cli are on the latest version, i.e. 0.19.0 The tests pass fine now. Phew!

These are my updated entries for anyone else having this issue. "composer-connector-embedded": "^0.19.0", "composer-cucumber-steps": "^0.19.0", "composer-admin": "^0.19.0", "composer-client": "^0.19.0", "composer-common": "^0.19.0", "composer-runtime": "^0.19.0", "composer-runtime-hlfv1": "^0.19.0"