File tree Expand file tree Collapse file tree 1 file changed +2
-13
lines changed
operator-framework/src/test/java/com/github/containersolutions/operator Expand file tree Collapse file tree 1 file changed +2
-13
lines changed Original file line number Diff line number Diff line change 10
10
import java .util .List ;
11
11
import java .util .concurrent .TimeUnit ;
12
12
13
- import static com .github .containersolutions .operator .IntegrationTestSupport .TEST_CUSTOM_RESOURCE_PREFIX ;
14
13
import static com .github .containersolutions .operator .IntegrationTestSupport .TEST_NAMESPACE ;
15
14
import static org .assertj .core .api .Assertions .assertThat ;
16
15
@@ -62,18 +61,8 @@ public void manyResourcesGetCreatedUpdatedAndDeleted() throws InterruptedExcepti
62
61
tcr .getSpec ().setValue (i + UPDATED_SUFFIX );
63
62
integrationTest .getCrOperations ().inNamespace (TEST_NAMESPACE ).createOrReplace (tcr );
64
63
}
65
-
66
- Awaitility .await ().atMost (1 , TimeUnit .MINUTES )
67
- .untilAsserted (() -> {
68
- List <TestCustomResource > crs = integrationTest .getCrOperations ()
69
- .inNamespace (TEST_NAMESPACE )
70
- .list ().getItems ();
71
- for (int i = 0 ; i < NUMBER_OF_RESOURCES_UPDATED ; i ++) {
72
- final int k = i ;
73
- TestCustomResource testCustomResource = crs .stream ().filter (c -> c .getMetadata ().getName ().equals (TEST_CUSTOM_RESOURCE_PREFIX + k )).findFirst ().get ();
74
- assertThat (testCustomResource .getSpec ().getValue ()).isEqualTo (i + UPDATED_SUFFIX );
75
- }
76
- });
64
+ // sleep to make some variability to the test, so some updates are not executed before delete
65
+ Thread .sleep (300 );
77
66
78
67
log .info ("Deleting resources." );
79
68
// deleting some resources
You can’t perform that action at this time.
0 commit comments