0

trying to run a test for my contract, but truffle test is just compiling the contracts and not running anything. my truffle.config does not specify a test network, which should result in truffle spawning a ganache instance when i run truffle test. Instead, I am getting the following:

enter image description here

and no further output.

here are the versions I'm using:

  • Truffle v5.5.19 (core: 5.5.19)
  • Ganache v7.2.0
  • Solidity - 0.8.9(solc-js)
  • Node v14.19.3
  • Web3.js v1.5.3

When I specify a network in truffle-config it works, but why isn't it creating its own ganache instance if I don't specify?

here is my truffle-config.js: enter image description here

Has anyone seen this before?

3
  • 1
    can you show your truffle-config.js file pls
    – sola24
    Jun 30, 2022 at 19:02
  • @sola24 edited to include truffle-config.js Jul 5, 2022 at 11:11
  • actually ... I mostly use hardhat but when I have used truffle I ran up the ganache blockchain independently/in advance, either with ganache-cli or the ganache gui version
    – sola24
    Jul 5, 2022 at 18:28

1 Answer 1

0

The reason is because inside the truffle -config file the truffle will recognise the default network and the solc compiler version, and you need to edit it according to your requirement!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.