anza-xyz / move

Move compiler targeting llvm supported backends
https://discord.gg/wFgfjG9J
Apache License 2.0
107 stars 32 forks source link

Print the full command line invocation when test fails #363

Closed ksolana closed 10 months ago

ksolana commented 10 months ago

Fixes: https://github.com/solana-labs/move/issues/276

Example: Now this command can be run directly on terminal to iterate fast on the specific test case.

Error: move-solana-build failed.
command:

MOVE_NATIVE="/run/media/adityak/tb_half/move/language/tools/move-mv-llvm-compiler/../../../language/move-native" "/run/media/adityak/tb_half/move/target/debug/move" "build" "--arch" "solana" "-p" "/run/media/adityak/tb_half/move/language/tools/move-mv-llvm-compiler/tests/rbpf-tests/basic"

stdout:

stderr:
COMPILING MoveStdlib, basic to SOLANA
Move source code errors Failed to compile Move into SOLANA ERROR
error: unexpected token
  ┌─ ./sources/basic.move:2:1
  │
2 │ asdfas
  │ ^^^^^^ Invalid code unit. Expected 'address', 'module', or 'script'. Got 'asdfas'

Error: Move source code errors