forked from TrueCloudLab/neoneo-go
core/tests: fix NameService test
We should look for the timestamp of the block with `register`.
This commit is contained in:
parent
71494e6ae4
commit
468dc5aad6
1 changed files with 2 additions and 3 deletions
|
@ -151,13 +151,12 @@ func TestRegisterAndRenew(t *testing.T) {
|
||||||
testNameServiceInvoke(t, bc, "balanceOf", 0, testchain.CommitteeScriptHash())
|
testNameServiceInvoke(t, bc, "balanceOf", 0, testchain.CommitteeScriptHash())
|
||||||
testNameServiceInvokeAux(t, bc, defaultRegisterSysfee, true, "register",
|
testNameServiceInvokeAux(t, bc, defaultRegisterSysfee, true, "register",
|
||||||
true, "neo.com", testchain.CommitteeScriptHash())
|
true, "neo.com", testchain.CommitteeScriptHash())
|
||||||
|
topBlock := bc.topBlock.Load().(*block.Block)
|
||||||
|
expectedExpiration := topBlock.Timestamp/1000 + secondsInYear
|
||||||
testNameServiceInvokeAux(t, bc, defaultRegisterSysfee, true, "register",
|
testNameServiceInvokeAux(t, bc, defaultRegisterSysfee, true, "register",
|
||||||
false, "neo.com", testchain.CommitteeScriptHash())
|
false, "neo.com", testchain.CommitteeScriptHash())
|
||||||
testNameServiceInvoke(t, bc, "isAvailable", false, "neo.com")
|
testNameServiceInvoke(t, bc, "isAvailable", false, "neo.com")
|
||||||
|
|
||||||
topBlock := bc.topBlock.Load().(*block.Block)
|
|
||||||
expectedExpiration := topBlock.Timestamp/1000 + secondsInYear
|
|
||||||
|
|
||||||
props := stackitem.NewMap()
|
props := stackitem.NewMap()
|
||||||
props.Add(stackitem.Make("name"), stackitem.Make("neo.com"))
|
props.Add(stackitem.Make("name"), stackitem.Make("neo.com"))
|
||||||
props.Add(stackitem.Make("description"), stackitem.Make(""))
|
props.Add(stackitem.Make("description"), stackitem.Make(""))
|
||||||
|
|
Loading…
Reference in a new issue