starcoinorg / starcoin-cookbook

The Cookbook for Starcoin & Move developer
https://cookbook.starcoin.org/
Apache License 2.0
51 stars 30 forks source link

about unit testing #216

Open willcking opened 11 months ago

willcking commented 11 months ago

I encountered an error when I studied the move-unit-test chapter according to the cookbook.

PS D:\CODE\Move\starcoin\TestExample> mpm package test
INCLUDING DEPENDENCY MoveStdlib
INCLUDING DEPENDENCY StarcoinFramework
INCLUDING DEPENDENCY UnitTest
BUILDING TestExample
thread 'main' panicked at 'assertion failed: !context.env.has_errors()', C:\Users\runneradmin\.cargo\git\checkouts\move-ae0d26a86327ae96\0b3686b\language\move-compiler\src\expansion\translate.rs:1236:13
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

This is my Move.toml file

[package]
name = "TestExample"
version = "0.0.0"

[dependencies]
MoveStdlib = { git = "https://github.com/move-language/move.git", subdir="language/move-stdlib", rev = "56ab033cc403b489e891424a629e76f643d4fb6b", addr_subst = { "std" = "0x1" } }
StarcoinFramework = {git = "https://github.com/starcoinorg/starcoin-framework.git", rev="cf1deda180af40a8b3e26c0c7b548c4c290cd7e7"}

[addresses]
StarcoinFramework =  "0x1"
Owner="0xAAAA"