@@ -69,9 +69,9 @@ func TestIntegration(t *testing.T) {
69
69
70
70
tests := map [string ]testCase {
71
71
"all-at-once-rollout-2-replicas" : {
72
- input : testhelpers .ModifyObj (common .MakeTWDWithName ("all-at-once-rollout-2-replicas" ), func (obj * temporaliov1alpha1.TemporalWorkerDeployment ) * temporaliov1alpha1.TemporalWorkerDeployment {
72
+ input : testhelpers .ModifyObj (testhelpers .MakeTWDWithName ("all-at-once-rollout-2-replicas" ), func (obj * temporaliov1alpha1.TemporalWorkerDeployment ) * temporaliov1alpha1.TemporalWorkerDeployment {
73
73
obj .Spec .RolloutStrategy .Strategy = temporaliov1alpha1 .UpdateAllAtOnce
74
- obj .Spec .Template = common .MakeHelloWorldPodSpec ("v1" )
74
+ obj .Spec .Template = testhelpers .MakeHelloWorldPodSpec ("v1" )
75
75
replicas := int32 (2 )
76
76
obj .Spec .Replicas = & replicas
77
77
obj .Spec .WorkerOptions = temporaliov1alpha1.WorkerOptions {
@@ -90,12 +90,12 @@ func TestIntegration(t *testing.T) {
90
90
TargetVersion : nil ,
91
91
CurrentVersion : & temporaliov1alpha1.CurrentWorkerDeploymentVersion {
92
92
BaseWorkerDeploymentVersion : temporaliov1alpha1.BaseWorkerDeploymentVersion {
93
- VersionID : common .MakeVersionId (testNamespace .Name , "all-at-once-rollout-2-replicas" , "v1" ),
93
+ VersionID : testhelpers .MakeVersionId (testNamespace .Name , "all-at-once-rollout-2-replicas" , "v1" ),
94
94
Deployment : & corev1.ObjectReference {
95
95
Namespace : testNamespace .Name ,
96
96
Name : k8s .ComputeVersionedDeploymentName (
97
97
"all-at-once-rollout-2-replicas" ,
98
- common .MakeBuildId ("all-at-once-rollout-2-replicas" , "v1" , nil ),
98
+ testhelpers .MakeBuildId ("all-at-once-rollout-2-replicas" , "v1" , nil ),
99
99
),
100
100
},
101
101
},
@@ -107,12 +107,12 @@ func TestIntegration(t *testing.T) {
107
107
},
108
108
},
109
109
"progressive-rollout-expect-first-step" : {
110
- input : testhelpers .ModifyObj (common .MakeTWDWithName ("progressive-rollout-expect-first-step" ), func (obj * temporaliov1alpha1.TemporalWorkerDeployment ) * temporaliov1alpha1.TemporalWorkerDeployment {
110
+ input : testhelpers .ModifyObj (testhelpers .MakeTWDWithName ("progressive-rollout-expect-first-step" ), func (obj * temporaliov1alpha1.TemporalWorkerDeployment ) * temporaliov1alpha1.TemporalWorkerDeployment {
111
111
obj .Spec .RolloutStrategy .Strategy = temporaliov1alpha1 .UpdateProgressive
112
112
obj .Spec .RolloutStrategy .Steps = []temporaliov1alpha1.RolloutStep {
113
- {5 , metav1.Duration {time .Hour }},
113
+ {RampPercentage : 5 , PauseDuration : metav1.Duration {Duration : time .Hour }},
114
114
}
115
- obj .Spec .Template = common .MakeHelloWorldPodSpec ("v1" )
115
+ obj .Spec .Template = testhelpers .MakeHelloWorldPodSpec ("v1" )
116
116
obj .Spec .WorkerOptions = temporaliov1alpha1.WorkerOptions {
117
117
TemporalConnection : "progressive-rollout-expect-first-step" ,
118
118
TemporalNamespace : ts .GetDefaultNamespace (),
@@ -128,12 +128,12 @@ func TestIntegration(t *testing.T) {
128
128
expectedStatus : & temporaliov1alpha1.TemporalWorkerDeploymentStatus {
129
129
TargetVersion : & temporaliov1alpha1.TargetWorkerDeploymentVersion {
130
130
BaseWorkerDeploymentVersion : temporaliov1alpha1.BaseWorkerDeploymentVersion {
131
- VersionID : common .MakeVersionId (testNamespace .Name , "progressive-rollout-expect-first-step" , "v1" ),
131
+ VersionID : testhelpers .MakeVersionId (testNamespace .Name , "progressive-rollout-expect-first-step" , "v1" ),
132
132
Deployment : & corev1.ObjectReference {
133
133
Namespace : testNamespace .Name ,
134
134
Name : k8s .ComputeVersionedDeploymentName (
135
135
"progressive-rollout-expect-first-step" ,
136
- common .MakeBuildId ("progressive-rollout-expect-first-step" , "v1" , nil ),
136
+ testhelpers .MakeBuildId ("progressive-rollout-expect-first-step" , "v1" , nil ),
137
137
),
138
138
},
139
139
},
@@ -145,12 +145,12 @@ func TestIntegration(t *testing.T) {
145
145
CurrentVersion : nil ,
146
146
RampingVersion : & temporaliov1alpha1.TargetWorkerDeploymentVersion {
147
147
BaseWorkerDeploymentVersion : temporaliov1alpha1.BaseWorkerDeploymentVersion {
148
- VersionID : common .MakeVersionId (testNamespace .Name , "progressive-rollout-expect-first-step" , "v1" ),
148
+ VersionID : testhelpers .MakeVersionId (testNamespace .Name , "progressive-rollout-expect-first-step" , "v1" ),
149
149
Deployment : & corev1.ObjectReference {
150
150
Namespace : testNamespace .Name ,
151
151
Name : k8s .ComputeVersionedDeploymentName (
152
152
"progressive-rollout-expect-first-step" ,
153
- common .MakeBuildId ("progressive-rollout-expect-first-step" , "v1" , nil ),
153
+ testhelpers .MakeBuildId ("progressive-rollout-expect-first-step" , "v1" , nil ),
154
154
),
155
155
},
156
156
},
0 commit comments