Skip to content

Commit

Permalink
Adding missing avoidDuplicateValues=true which fixes failing test.
Browse files Browse the repository at this point in the history
  • Loading branch information
semancik committed Nov 27, 2015
1 parent 59c37c9 commit 0ca5e13
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 20 deletions.
@@ -1,6 +1,6 @@
package com.evolveum.midpoint.testing.story;
/*
* Copyright (c) 2013 Evolveum
* Copyright (c) 2013-2015 Evolveum
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -186,8 +186,8 @@ public void test000Sanity() throws Exception {
}

@Test
public void test100jackAssignRoleStatistics() throws Exception {
final String TEST_NAME = "test100jackAssignRoleStatistics";
public void test100JackAssignRoleStatistics() throws Exception {
final String TEST_NAME = "test100JackAssignRoleStatistics";
TestUtil.displayTestTile(this, TEST_NAME);
Task task = taskManager.createTaskInstance(TestScience.class.getName() + "." + TEST_NAME);

Expand Down Expand Up @@ -229,8 +229,8 @@ public void test100jackAssignRoleStatistics() throws Exception {
}

@Test
public void test101unassignRoleStats() throws Exception{
final String TEST_NAME = "test101unassignRoleStats";
public void test101UnassignRoleStats() throws Exception{
final String TEST_NAME = "test101UnassignRoleStats";
TestUtil.displayTestTile(this, TEST_NAME);
Task task = taskManager.createTaskInstance(TestScience.class.getName() + "." + TEST_NAME);

Expand Down Expand Up @@ -279,8 +279,8 @@ public void test101unassignRoleStats() throws Exception{
}

@Test
public void test102assignRoleStats() throws Exception{
final String TEST_NAME = "test102assignRoleStats";
public void test102AssignRoleStats() throws Exception{
final String TEST_NAME = "test102AssignRoleStats";
TestUtil.displayTestTile(this, TEST_NAME);
Task task = taskManager.createTaskInstance(TestScience.class.getName() + "." + TEST_NAME);

Expand Down Expand Up @@ -327,15 +327,17 @@ public void test102assignRoleStats() throws Exception{


@Test
public void test200delteUserJack() throws Exception {
final String TEST_NAME = "test200delteUserJack";
public void test200DelteUserJack() throws Exception {
final String TEST_NAME = "test200DelteUserJack";
TestUtil.displayTestTile(this, TEST_NAME);
Task task = taskManager.createTaskInstance(TestScience.class.getName() + "." + TEST_NAME);

OperationResult result = task.getResult();

// WHEN
deleteObject(UserType.class, USER_JACK_OID, task, result);

// THEN
result.computeStatus();

IntegrationTestTools.display("Result: ", result);
Expand All @@ -344,16 +346,8 @@ public void test200delteUserJack() throws Exception {
AssertJUnit.fail("Expected success or handled error, but got "+result.getStatus());
}

try {
repositoryService.getObject(UserType.class, USER_JACK_OID, null, result);
AssertJUnit.fail("Unexpected user jack. It must not exist.");
} catch (ObjectNotFoundException ex){
//this is OK
}

assertNoObject(UserType.class, USER_JACK_OID, task, result);

}


}

}
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright (c) 2010-2014 Evolveum
~ Copyright (c) 2010-2015 Evolveum
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -264,6 +264,10 @@
</objectType>
</schemaHandling>

<consistency>
<avoidDuplicateValues>true</avoidDuplicateValues>
</consistency>

<synchronization>
<objectSynchronization>
<enabled>true</enabled>
Expand Down

0 comments on commit 0ca5e13

Please sign in to comment.