@@ -127,7 +127,7 @@ public static void initAll(@Namespaces(2) List<String> namespaces) {
127
127
// create a basic model in image domain
128
128
createAndVerifyMiiDomain (imageName );
129
129
130
- // create temp file
130
+ // create temp file to be copied to managed server pod which will be used in customLivenessProbe.sh
131
131
String fileName = "tempFile" ;
132
132
tempFile = assertDoesNotThrow (() -> createTempfile (fileName ), "Failed to create temp file" );
133
133
logger .info ("File created {0}" , tempFile );
@@ -323,11 +323,6 @@ void testCustomLivenessProbeFailureThresholdSuccessThreshold() {
323
323
logger .info ("livenessProbe failureThreshold after patch is: {0}" , failureThreshold );
324
324
assertTrue (failureThreshold .intValue () == 3 , "The livenessProbe failureThreshold after patch is not 3" );
325
325
326
- // get the successThreshold of livenessProbe after patch
327
- successThreshold = domain1 .getSpec ().getServerPod ().getLivenessProbe ().getSuccessThreshold ();
328
- logger .info ("livenessProbe successThreshold after patch is: {0}" , successThreshold );
329
- assertTrue (successThreshold .intValue () == 1 , "The livenessProbe successThreshold after patch is not 1" );
330
-
331
326
// verify the failureThreshold behavior of livenessProbe
332
327
// copy temp file to pod and verify the restartCount only happens after 1m 30 second
333
328
for (int i = 1 ; i <= NUMBER_OF_CLUSTERS_MIIDOMAIN ; i ++) {
@@ -358,13 +353,13 @@ void testCustomLivenessProbeFailureThresholdSuccessThreshold() {
358
353
} catch (InterruptedException ie ) {
359
354
// ignore
360
355
}
361
- int after1mRestartCount =
356
+ int afterDeplayRestartCount =
362
357
assertDoesNotThrow (() -> getContainerRestartCount (domainNamespace , null ,
363
358
managedServerPodName , null ),
364
359
String .format ("Failed to get the restart count of the container from pod {0} in namespace {1} after 1m" ,
365
360
managedServerPodName , domainNamespace ));
366
361
logger .info ("checking after 45s the restartCount is not changed." );
367
- assertTrue (beforeRestartCount == after1mRestartCount , "The pod was restarted after 45s, "
362
+ assertTrue (beforeRestartCount == afterDeplayRestartCount , "The pod was restarted after 45s, "
368
363
+ "it should restart after that" );
369
364
370
365
String expectedStr = "Hello World, you have reached server "
0 commit comments