Truffle tests not running after truffle init

0 votes

I am trying to build a dapp using truffle on my Mac OSX. I have installed Testrpc and Truffle globally with NPM. I ran testrpc in a terminal window and ran truffle test. I get 2 passing and 3 failing tests. The three failing tests are

TestMetacoin testInitialBalanceUsingDeployedContract:

TestMetacoin testInitialBalanceWithNewMetaCoin:

and

Contract: MetaCoin should send coin correctly:

each is failing at the same place:

Uncaught TypeError: Cannot read property '1' of undefined
  at /usr/local/lib/node_modules/truffle/node_modules/ethjs-abi/lib/index.js:139:34
  at Array.map (native)
  at Object.decodeEvent (/usr/local/lib/node_modules/truffle/node_modules/ethjs-abi/lib/index.js:138:6)
  at /usr/local/lib/node_modules/truffle/node_modules/truffle-contract/contract.js:73:38
  at Array.map (native)
  at Object.decodeLogs (/usr/local/lib/node_modules/truffle/node_modules/truffle-contract/contract.js:44:19)
  at Object.callback (/usr/local/lib/node_modules/truffle/node_modules/truffle-contract/contract.js:172:35)
  at /usr/local/lib/node_modules/truffle/node_modules/truffle-contract/node_modules/web3/lib/web3/method.js:142:25
  at /usr/local/lib/node_modules/truffle/node_modules/truffle-contract/node_modules/web3/lib/web3/requestmanager.js:89:9
  at XMLHttpRequest.request.onreadystatechange (/usr/local/lib/node_modules/truffle/node_modules/web3/lib/web3/httpprovider.js:119:13)
  at XMLHttpRequestEventTarget.dispatchEvent (/usr/local/lib/node_modules/truffle/node_modules/xhr2/lib/xhr2.js:64:18)
  at XMLHttpRequest._setReadyState (/usr/local/lib/node_modules/truffle/node_modules/xhr2/lib/xhr2.js:354:12)
  at XMLHttpRequest._onHttpResponseEnd (/usr/local/lib/node_modules/truffle/node_modules/xhr2/lib/xhr2.js:509:12)
  at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/truffle/node_modules/xhr2/lib/xhr2.js:469:24)

I am sure I am missing something simple, any help is appreciated.

Sep 11, 2018 in Blockchain by sabby
• 4,350 points
105 views

1 answer to this question.

0 votes
This was a bug. They've fixed it. So, just re-install truffle :p
answered Sep 11, 2018 by Christine
• 15,790 points

Related Questions In Blockchain

0 votes
1 answer

Not able to migrate truffle project even after running testrpc

Maybe you forgot to compile the project ...READ MORE

answered Dec 11, 2018 in Blockchain by Omkar
• 67,120 points
52 views
0 votes
1 answer
+1 vote
5 answers

How to solve "truffle: command not found" error in blockchain?

First try restarting the system and then ...READ MORE

answered Jul 16, 2018 in Blockchain by slayer
• 29,050 points
671 views
0 votes
1 answer
0 votes
1 answer

Protocols used in a distributed/dlt system for the nodes to establish communication

yes all are over TCP/IP connections secured by TLS encryption in hashgraph architecture-hashgraph, ...READ MORE

answered Aug 6, 2018 in Blockchain by ariaholic
• 7,320 points
56 views
0 votes
1 answer

Why am I not getting 100 ethers in my metamask account?

Sorry that you're having this problem. To ...READ MORE

answered Jun 14, 2018 in Blockchain by Christine
• 15,790 points
111 views
0 votes
1 answer

Why do the resultant hash after mining has a leading no. of zeroes in Blockchain verification?

This is chosen by the DIFFICULTY EQUATION. In ...READ MORE

answered Aug 10, 2018 in Blockchain by Christine
• 15,790 points
34 views