[#170] oid, cid: Add marshal format checks

Also add checking presence of the `oid`, `cid` fields via `set` flag.

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
Pavel Karpy 2022-04-12 19:23:16 +03:00 committed by LeL
parent f7172adf18
commit 1186f2f703
17 changed files with 432 additions and 118 deletions

View file

@ -19,6 +19,8 @@ func TestInitCreation(t *testing.T) {
Owner: own,
})
require.Equal(t, cnr, o.ContainerID())
cID, set := o.ContainerID()
require.True(t, set)
require.Equal(t, cnr, cID)
require.Equal(t, &own, o.OwnerID())
}