Skip to content

Commit b2e34e8

Browse files
committed
fix test
Signed-off-by: Kesha Hietala <[email protected]>
1 parent 145c3c6 commit b2e34e8

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

cedar-policy-validator/src/typecheck/test_namespace.rs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,13 @@ use cedar_policy_core::{
3030
};
3131

3232
use super::test_utils::{
33-
assert_policy_typecheck_fails, assert_policy_typechecks, assert_typecheck_fails,
34-
assert_typechecks,
33+
assert_policy_typecheck_fails, assert_policy_typecheck_warns, assert_policy_typechecks,
34+
assert_typecheck_fails, assert_typechecks,
3535
};
3636
use crate::{
3737
type_error::TypeError,
3838
types::{EntityLUB, Type},
39-
AttributeAccess, SchemaError, SchemaFragment, ValidatorSchema,
39+
AttributeAccess, SchemaError, SchemaFragment, ValidationWarningKind, ValidatorSchema,
4040
};
4141

4242
fn namespaced_entity_type_schema() -> SchemaFragment {
@@ -561,10 +561,10 @@ fn multi_namespace_action_eq() {
561561
r#"permit(principal, action, resource) when { NS1::Action::"Action" == NS2::Action::"Action" };"#,
562562
)
563563
.unwrap();
564-
assert_policy_typecheck_fails(
564+
assert_policy_typecheck_warns(
565565
schema.clone(),
566566
policy.clone(),
567-
vec![TypeError::impossible_policy(policy.condition())],
567+
vec![ValidationWarningKind::ImpossiblePolicy],
568568
);
569569
}
570570

@@ -621,10 +621,10 @@ fn multi_namespace_action_in() {
621621
r#"permit(principal, action in NS4::Action::"Group", resource);"#,
622622
)
623623
.unwrap();
624-
assert_policy_typecheck_fails(
624+
assert_policy_typecheck_warns(
625625
schema.clone(),
626626
policy.clone(),
627-
vec![TypeError::impossible_policy(policy.condition())],
627+
vec![ValidationWarningKind::ImpossiblePolicy],
628628
);
629629
}
630630

0 commit comments

Comments
 (0)