From 58a778914c471b31cbaf55d6cec79f013f428e5c Mon Sep 17 00:00:00 2001 From: Kevin DeJong Date: Mon, 21 Oct 2024 12:22:15 -0700 Subject: [PATCH] Update more tests for condition keys --- test/unit/rules/resources/iam/test_identity_policy.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/test/unit/rules/resources/iam/test_identity_policy.py b/test/unit/rules/resources/iam/test_identity_policy.py index c526e1baf2..ced3940fc7 100644 --- a/test/unit/rules/resources/iam/test_identity_policy.py +++ b/test/unit/rules/resources/iam/test_identity_policy.py @@ -186,7 +186,10 @@ def test_string_statements_with_condition(self): "IpAddress": {"aws:SourceIp": "203.0.113.0/24"}, "ArnEquals": {"aws:SourceArn": "arn:aws:sns:REGION:123456789012:TOPIC-ID"}, "StringLikeIfExists": { "ec2:InstanceType": [ "t1.*", "t2.*" ]}, - "Null":{"aws:TokenIssueTime":"true"} + "Null":{"aws:TokenIssueTime":"true"}, + "ForAllValues:StringEquals":{"aws:PrincipalTag/job-category":["iamuser-admin","iamuser-read-only"]}, + "ForAnyValue:StringEquals":{"aws:PrincipalTag/job-category":"iamuser-admin"}, + "ForAllValues:StringLike": {"aws:TagKeys": ["key1*"]} } } ]