0

我正在尝试测试我的第一个区块链应用程序。这是我的代码

var Contest = artifacts.require("./Contest.sol");
contract("Contest",function(accounts){
//to check if getting initialized correctly
it("initializes with two contestants", function(){
    return Contest.deployed().then(function(instance){
        return instance.contestantsCount();
    }).then(function(count){
        assert.equal(count,2);
    });
});
});

但我收到此错误:

TypeError [ERR_INVALID_REPL_INPUT] [ERR_INVALID_REPL_INPUT]: Listeners 
for `uncaughtException` cannot be used in the REPL

环境

Operating System: Microsoft Windows
Truffle v5.0.2 (core: 5.0.2)
Solidity v0.5.0 (solc-js)
Node v14.17.1
4

1 回答 1

0

不应该有逗号。它应该是:

X = faces[::-1]
y = faces[:-1:]
于 2020-11-06T06:03:30.373 回答