MCPcopy Create free account
hub / github.com/DNAProject/DNA / NewDeployNeoContract

Function NewDeployNeoContract

wasmtest/wasm-test.go:77–89  ·  view source on GitHub ↗
(signer *account.Account, code []byte)

Source from the content-addressed store, hash-verified

75}
76
77func NewDeployNeoContract(signer *account.Account, code []byte) (*types.Transaction, error) {
78 mutable, err := utils.NewDeployCodeTransaction(0, 100000000, code, payload.NEOVM_TYPE, "name", "version",
79 "author", "email", "desc")
80 if err != nil {
81 return nil, err
82 }
83 err = utils.SignTransaction(signer, mutable)
84 if err != nil {
85 return nil, err
86 }
87 tx, err := mutable.IntoImmutable()
88 return tx, err
89}
90
91func GenNeoTextCaseTransaction(contract common.Address, database *ledger.Ledger) [][]common3.TestCase {
92 params := make([]interface{}, 0)

Callers 1

mainFunction · 0.85

Calls 1

IntoImmutableMethod · 0.80

Tested by

no test coverage detected