首页 > 解决方案 > 在结构项目中运行测试用例失败,版本 release1.2

问题描述

在./core/chaincode/exectransaction_test.go目录下
运行795行TestExecuteDeployTransaction函数,报错:

2019-01-17 09:37:18.925 CST [ledgermgmt] initialize -> INFO 003 Initializing ledger mgmt
2019-01-17 09:37:18.925 CST [kvledger] NewProvider -> INFO 004 Initializing ledger provider
2019-01-17 09:37:20.113 CST [kvledger] NewProvider -> INFO 005 ledger provider Initialized
2019-01-17 09:37:20.114 CST [ledgermgmt] initialize -> INFO 006 ledger mgmt initialized
2019-01-17 09:37:20.118 CST [sccapi] registerSysCC -> INFO 007 system chaincode cscc(github.com/hyperledger/fabric/core/scc/cscc) registered
2019-01-17 09:37:20.118 CST [sccapi] registerSysCC -> INFO 008 system chaincode lscc(github.com/hyperledger/fabric/core/scc/lscc) registered
2019-01-17 09:37:20.118 CST [sccapi] registerSysCC -> INFO 009 system chaincode (qscc,github.com/hyperledger/fabric/core/scc/qscc,true) disabled
2019-01-17 09:37:20.443 CST [ledgermgmt] CreateLedger -> INFO 00a Creating ledger [testchainid] with genesis block
2019-01-17 09:37:20.493 CST [fsblkstorage] newBlockfileMgr -> INFO 00b Getting block information from block storage
2019-01-17 09:37:20.731 CST [kvledger] CommitWithPvtData -> INFO 00c Channel [testchainid]: Committed block [0] with 1 transaction(s)
2019-01-17 09:37:20.731 CST [pvtdatastorage] func1 -> INFO 00d Purger started: Purging expired private data till block number [0]
2019-01-17 09:37:20.732 CST [pvtdatastorage] func1 -> INFO 00e Purger finished
2019-01-17 09:37:20.884 CST [ledgermgmt] CreateLedger -> INFO 00f Created ledger [testchainid] with genesis block
2019-01-17 09:37:20.886 CST [cscc] Init -> INFO 010 Init CSCC
2019-01-17 09:37:20.887 CST [sccapi] deploySysCC -> INFO 011 system chaincode cscc/testchainid(github.com/hyperledger/fabric/core/scc/cscc) deployed
2019-01-17 09:37:20.887 CST [sccapi] deploySysCC -> INFO 012 system chaincode lscc/testchainid(github.com/hyperledger/fabric/core/scc/lscc) deployed
2019-01-17 09:37:20.887 CST [sccapi] deploySysCC -> INFO 013 system chaincode (qscc,github.com/hyperledger/fabric/core/scc/qscc) disabled
getting deployment spec for chaincode spec: type:GOLANG chaincode_id:<path:"github.com/hyperledger/fabric/examples/chaincode/go/example01" name:"example01" version:"0" > input:<args:"init" args:"a" args:"100" args:"b" args:"200" > 
2019-01-17 09:37:22.129 CST [msp] DeserializeIdentity -> INFO 014 Obtaining identity
2019-01-17 09:37:22.777 CST [dockercontroller] func2 -> INFO 015 Container example01-0 has closed its IO channel
2019-01-17 09:37:22.940 CST [dockercontroller] Start -> ERRO 016 start-could not start container: API error (400): OCI runtime create failed: container_linux.go:348: starting container process caused "exec: \"chaincode\": executable file not found in $PATH": unknown
2019-01-17 09:37:22.983 CST [chaincode] Launch -> ERRO 017 start failed: API error (400): OCI runtime create failed: container_linux.go:348: starting container process caused "exec: \"chaincode\": executable file not found in $PATH": unknown
error starting container
error starting container

标签: hyperledger-fabric

解决方案


推荐阅读