Object quotas implementation
This commit is contained in:
@@ -590,14 +590,14 @@ impl From<Principal> for TestPrincipal {
|
||||
Self {
|
||||
id: value.id(),
|
||||
typ: value.typ(),
|
||||
quota: value.quota(),
|
||||
member_of: value.member_of().iter().map(|v| v.to_string()).collect(),
|
||||
roles: value.roles().iter().map(|v| v.to_string()).collect(),
|
||||
lists: value.lists().iter().map(|v| v.to_string()).collect(),
|
||||
quota: value.quota().unwrap_or_default(),
|
||||
member_of: value.member_of().map(|v| v.to_string()).collect(),
|
||||
roles: value.roles().map(|v| v.to_string()).collect(),
|
||||
lists: value.lists().map(|v| v.to_string()).collect(),
|
||||
secrets: value.secrets().map(|v| v.to_string()).collect(),
|
||||
emails: value.emails().map(|v| v.to_string()).collect(),
|
||||
description: value.description().map(|v| v.to_string()),
|
||||
name: value.name,
|
||||
secrets: value.secrets,
|
||||
emails: value.emails,
|
||||
description: value.description,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -132,7 +132,7 @@ async fn oidc_directory() {
|
||||
.unwrap();
|
||||
assert_eq!(principal.name(), "jdoe");
|
||||
assert_eq!(
|
||||
principal.emails.first().map(|s| s.as_str()),
|
||||
principal.emails().next().map(|s| s.as_str()),
|
||||
Some("john@example.org")
|
||||
);
|
||||
assert_eq!(principal.description(), Some("John Doe"));
|
||||
|
||||
Reference in New Issue
Block a user