1
0
mirror of https://github.com/matrix-org/matrix-authentication-service.git synced 2025-07-29 22:01:14 +03:00

Fix policy test

This commit is contained in:
Quentin Gliech
2022-06-04 12:47:36 +02:00
parent 5a4a4ed21e
commit 581e011c7b

View File

@ -216,19 +216,19 @@ mod tests {
let mut policy = factory.instantiate().await.unwrap(); let mut policy = factory.instantiate().await.unwrap();
let res = policy let res = policy
.evaluate_register("hello", "hello@example.com", "hunter2") .evaluate_register("hello", "hunter2", "hello@example.com")
.await .await
.unwrap(); .unwrap();
assert!(!res.valid()); assert!(!res.valid());
let res = policy let res = policy
.evaluate_register("hello", "hello@foo.element.io", "hunter2") .evaluate_register("hello", "hunter2", "hello@foo.element.io")
.await .await
.unwrap(); .unwrap();
assert!(res.valid()); assert!(res.valid());
let res = policy let res = policy
.evaluate_register("hello", "hello@staging.element.io", "hunter2") .evaluate_register("hello", "hunter2", "hello@staging.element.io")
.await .await
.unwrap(); .unwrap();
assert!(!res.valid()); assert!(!res.valid());