Skip to content

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/origin/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
skublik committed Sep 9, 2021
2 parents cb36bfc + 65cd02e commit 1681317
Showing 1 changed file with 18 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -417,12 +417,26 @@ public void test110SearchUserByName() throws Exception {
* * String value is normalized as configured for norm matching (as demonstrated in this test).
*/
@Test
public void test110SearchUserByNameNormalized() throws Exception {
public void test111SearchUserByNameNormalized() throws Exception {
searchUsersTest("with normalized name matching provided value",
f -> f.item(UserType.F_NAME).eq("UseR--2").matchingNorm(),
user2Oid);
}

/**
* Multi-value EQ filter (multiple values on the right-hand side) works like `IN`,
* that is if any of the values matches, the object matches and is returned.
*/
@Test
public void test115SearchUserByAnyOfName() throws Exception {
searchUsersTest("with name matching any of provided values (multi-value EQ filter)",
f -> f.item(UserType.F_NAME).eq(
PolyString.fromOrig("user-1"),
PolyString.fromOrig("user-2"),
PolyString.fromOrig("user-wrong")), // bad value is of no consequence
user1Oid, user2Oid);
}

@Test
public void test120SearchObjectsBySubtype() throws Exception {
searchObjectTest("having subtype equal to value", ObjectType.class,
Expand Down Expand Up @@ -1737,9 +1751,10 @@ public void test800SearchUsersWithSimplePath() throws SchemaException {
@Test(expectedExceptions = SystemException.class)
public void test820SearchUsersWithReferencedPath() throws SchemaException {
searchUsersTest("fullName does not equals fname",
f -> f.not().item(ObjectType.F_METADATA, MetadataType.F_CREATE_TIMESTAMP).eq().item(UserType.F_ASSIGNMENT, AssignmentType.F_METADATA, MetadataType.F_CREATE_TIMESTAMP),
f -> f.not().item(ObjectType.F_METADATA, MetadataType.F_CREATE_TIMESTAMP)
.eq().item(UserType.F_ASSIGNMENT, AssignmentType.F_METADATA, MetadataType.F_CREATE_TIMESTAMP),
user1Oid, user2Oid, user3Oid, user4Oid);
// Should fail because right hand side nesting into multivalue container is not supported
// Should fail because right-hand side nesting into multivalue container is not supported
}

// region special cases
Expand Down

0 comments on commit 1681317

Please sign in to comment.