diff --git a/tests/policy_test.go b/tests/policy_test.go index e7fd489..ea72f73 100644 --- a/tests/policy_test.go +++ b/tests/policy_test.go @@ -100,6 +100,12 @@ func TestPolicy(t *testing.T) { checkTargets(t, e, policy.Namespace, [][]byte{[]byte("mynamespace")}) checkTargets(t, e, policy.Container, [][]byte{[]byte("cnr1")}) }) + + t.Run("large entityname", func(t *testing.T) { + largeEntityName := "thisisverylargeentitynamethatcontainverylargenamespaceanduseraddress" + e.Invoke(t, stackitem.Null{}, "addChain", policy.User, largeEntityName, "s3:somerule", p1) + checkTargets(t, e, policy.User, [][]byte{[]byte(largeEntityName)}) + }) } func TestAutorization(t *testing.T) {