나는 hyperledger/패브릭 프로젝트를 포크하고 내의 repo에서 나는 다음과 같은 명령을 사용하여 ECA에 대한 단위 테스트를 실행하려고 : 나는 다음과 같은 오류를 얻을 그러나 :membersrvc 내 단위 테스트를 golang 실행할 수 없음/캘리포니아
나는 최근에 내 포크를 업데이트[email protected]:v0.0.10-37b6688:/opt/gopath/src/github.com/hyperledger/fabric/membersrvc/ca$ go test ca_test.go
command-line-arguments
ca_test.go:28:2: cannot find package "command-/vendor/github.com/spf13/viper" in any of: /opt/go/src/command-/vendor/github.com/spf13/viper (from $GOROOT)
/opt/gopath/src/command-/vendor/github.com/spf13/viper (from >$GOPATH)
FAIL command-line-arguments [setup failed]
몇 일 다시 나를 위해에서 일하기 위하여 사용이 하지만 이후 : 나는 CA 단위 테스트를 실행하려고하면
[email protected]:v0.0.10-37b6688:/opt/gopath/src/github.com/hyperledger/fabric/membersrvc/ca$ go test eca_test.go
command-line-arguments
eca_test.go:30:2: cannot find package "command-/vendor/github.com/golang/protobuf/proto" in any of:
/opt/go/src/command-/vendor/github.com/golang/protobuf/proto (from $GOROOT)
/opt/gopath/src/command-/vendor/github.com/golang/protobuf/proto (from $GOPATH)
FAIL command-line-arguments [setup failed]
마찬가지로 나는 다음과 같은 오류가 발생합니다 하이퍼 링크에서 바뀐다. R/프로젝트는 내가 테스트 여기
를 실행할 수 아니에요의 내 GOPATH의 값 : 나는 왜 golang 빌드 시스템 경로에 "- 명령/공급 업체"를 추가한다 모르겠어요
[email protected]:v0.0.10-37b6688:/opt/gopath/src/github.com/hyperledger/fabric$ echo $GOPATH /opt/gopath
때를 가져온 패키지를 찾고 있습니다. 아무도 나를 도와 줄 수 없습니까?
감사합니다. Sergey, 맞아요. 추가하기 만하면 다른 사용자의 이익을 위해 하이퍼 리더에서 모든 단위 테스트를 실행하는 공식적인 방법은 "단위 테스트 만들기"명령을 실행하여 최상위 디렉토리/하이퍼 리더/패브릭에서 수행합니다 –