Syntax is correct. It looks like there could be hal engine error that doesn't treat EndRecordAdd the same as EndRecord when recompiling. And that could cause EndArray not being activated, so it looks for EndArray in the next defined record(TestBlock in this case).
As a workaround you can add CommodityVc definition to the end of the file.
p.s. repeatable on macosx single user mode