let template = Resources.*[ Type == 'AWS::New::Service'] rule TEST_COLLECTION when %template !empty { let collection = %template.Collection.* let res = join(%collection, ",") %res == "a,b" "a,b" == join(%collection, ",") << Violation: The joined value does not match the expected result >> }