@@ -952,22 +952,23 @@ class Tests(object):
952952 test .add_stonith_neg_log_pattern ("does not advertise support for 'reboot', performing 'off'" )
953953 test .add_stonith_log_pattern ("with device 'true1' returned: 0 (OK)" )
954954
955- # make sure enforced fencing delay is applied only for the first device in the first level
955+ # make sure requested fencing delay is applied only for the first device in the first level
956+ # make sure static delay from pcmk_delay_base is added
956957 for test_type in test_types :
957958 if test_type ["use_cpg" ] == 0 :
958959 continue
959960
960961 test = self .new_test ("%s_topology_delay" % test_type ["prefix" ],
961- "Verify enforced fencing delay is applied only for the first device in the first level." ,
962+ "Verify requested fencing delay is applied only for the first device in the first level and pcmk_delay_base is added ." ,
962963 test_type ["use_cpg" ])
963964 test .add_cmd ("stonith_admin" ,
964- "-R true1 -a fence_dummy -o \" mode=pass\" -o \" pcmk_host_list=node1 node2 node3\" " )
965+ "-R true1 -a fence_dummy -o \" mode=pass\" -o \" pcmk_host_list=node1 node2 node3\" -o \" pcmk_delay_base=1 \" " )
965966 test .add_cmd ("stonith_admin" ,
966- "-R false1 -a fence_dummy -o \" mode=fail\" -o \" pcmk_host_list=node1 node2 node3\" " )
967+ "-R false1 -a fence_dummy -o \" mode=fail\" -o \" pcmk_host_list=node1 node2 node3\" -o \" pcmk_delay_base=1 \" " )
967968 test .add_cmd ("stonith_admin" ,
968- "-R true2 -a fence_dummy -o \" mode=pass\" -o \" pcmk_host_list=node1 node2 node3\" " )
969+ "-R true2 -a fence_dummy -o \" mode=pass\" -o \" pcmk_host_list=node1 node2 node3\" " )
969970 test .add_cmd ("stonith_admin" ,
970- "-R true3 -a fence_dummy -o \" mode=pass\" -o \" pcmk_host_list=node1 node2 node3\" " )
971+ "-R true3 -a fence_dummy -o \" mode=pass\" -o \" pcmk_host_list=node1 node2 node3\" " )
971972
972973 test .add_cmd ("stonith_admin" , "-r node3 -i 1 -v true1" )
973974 test .add_cmd ("stonith_admin" , "-r node3 -i 1 -v false1" )
@@ -976,8 +977,8 @@ class Tests(object):
976977
977978 test .add_cmd ("stonith_admin" , "-F node3 --delay 1" )
978979
979- test .add_stonith_log_pattern ("Delaying 'off' action targeting node3 on true1 for enforced 1s " )
980- test .add_stonith_neg_log_pattern ("Delaying 'off' action targeting node3 on false1" )
980+ test .add_stonith_log_pattern ("Delaying 'off' action targeting node3 on true1 for 2s (timeout=120s, requested_delay=1s, base=1s, max=1s) " )
981+ test .add_stonith_log_pattern ("Delaying 'off' action targeting node3 on false1 for 1s (timeout=120s, requested_delay=0s, base=1s, max=1s) " )
981982 test .add_stonith_neg_log_pattern ("Delaying 'off' action targeting node3 on true2" )
982983 test .add_stonith_neg_log_pattern ("Delaying 'off' action targeting node3 on true3" )
983984
0 commit comments