neo-vm icon indicating copy to clipboard operation
neo-vm copied to clipboard

What is the purpose of the second assert of this test?

Open ixje opened this issue 2 years ago • 1 comments

https://github.com/neo-project/neo-vm/pull/454 added this test

https://github.com/neo-project/neo-vm/blob/81dc479902e22d906d58571c89bb858bb47899d1/tests/Neo.VM.Tests/UtStruct.cs#L44-L61

I'm trying to understand the intention of the second assert https://github.com/neo-project/neo-vm/blob/81dc479902e22d906d58571c89bb858bb47899d1/tests/Neo.VM.Tests/UtStruct.cs#L56-L61

It fails at exactly the same point as the first one (L49-L54) and after the exactly same amount of looping in Struct (here). The only difference being this part that is called a 1000 times more https://github.com/neo-project/neo-vm/blob/81dc479902e22d906d58571c89bb858bb47899d1/src/Neo.VM/Types/Struct.cs#L119-L122

which makes me wonder if it's actually testing what it was intended to test.

ixje avatar Jun 21 '22 12:06 ixje

I think that can be removed

shargon avatar Jun 21 '22 12:06 shargon