Commit 408e5e7 1 parent 4e9ed5f commit 408e5e7 Copy full SHA for 408e5e7
File tree 3 files changed +474
-175
lines changed
3 files changed +474
-175
lines changed Original file line number Diff line number Diff line change @@ -92,7 +92,30 @@ func TestTracker_Checks_Healthy(t *testing.T) {
92
92
func TestTracker_Checks_PendingPostStop_Healthy (t * testing.T ) {
93
93
t .Parallel ()
94
94
95
- alloc := mock .LifecycleAllocWithPoststopDeploy ()
95
+ alloc := mock .LifecycleAllocFromTasks ([]mock.LifecycleTaskDef {
96
+ {
97
+ Name : "web" ,
98
+ RunFor : "1s" ,
99
+ },
100
+ {
101
+ Name : "side" ,
102
+ RunFor : "1s" ,
103
+ Hook : structs .TaskLifecycleHookPrestart ,
104
+ IsSidecar : true ,
105
+ },
106
+ {
107
+ Name : "post" ,
108
+ RunFor : "1s" ,
109
+ Hook : structs .TaskLifecycleHookPoststop ,
110
+ },
111
+ {
112
+ Name : "init" ,
113
+ RunFor : "1s" ,
114
+ Hook : structs .TaskLifecycleHookPrestart ,
115
+ IsSidecar : false ,
116
+ },
117
+ })
118
+
96
119
alloc .Job .TaskGroups [0 ].Migrate .MinHealthyTime = 1 // let's speed things up
97
120
98
121
// Synthesize running alloc and tasks
You can’t perform that action at this time.
0 commit comments