use-ink/ink-examples

e2e tests are failing

Closed this issue · 5 comments

in flipper directory when running:

cargo test --features e2e-tests

getting this error:

  --> lib.rs:62:9
   |
62 |         #[ink_e2e::test]
   |         ^^^^^^^^^^^^^^^^
   |
   = help: message: contract build for /home/nikhil/astar/ink-examples/flipper/Cargo.toml failed: Loading of original wasm failed

error: custom attribute panicked
  --> lib.rs:94:9
   |
94 |         #[ink_e2e::test]
   |         ^^^^^^^^^^^^^^^^
   |
   = help: message: Once instance has previously been poisoned

warning: unused import: `super::*`
  --> lib.rs:57:13
   |
57 |         use super::*;
   |             ^^^^^^^^
   |
   = note: `#[warn(unused_imports)]` on by default

warning: unused import: `ink_e2e::build_message`
  --> lib.rs:58:13
   |
58 |         use ink_e2e::build_message;
   |             ^^^^^^^^^^^^^^^^^^^^^^

warning: `flipper` (lib test) generated 2 warnings
error: could not compile `flipper` (lib test) due to 2 previous errors; 2 warnings emitted

I have tried this and it works for me. The original issue appears to be:

Loading of original wasm failed.

Can you do a cargo clean or even better a git clean -xdf (making sure you have any changes you want to keep committed) and run it again?

Same error after cleaning

gangov commented

I can also confirm that cargo test --features e2e-tests runs fine. I'm using the latest ink version on my machine

Please confirm that you are using the latest version of cargo-contract and substrate-contracts-node and the node is installed in your path

I got it to work by reinstalling substrate-contracts-node