@@ -135,7 +135,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
135135 manifests , err := fullRun .Run (nil )
136136 Expect (err ).ToNot (HaveOccurred ())
137137 fullChartInstall , err := os .ReadFile (filepath .Join (customManifestsFolder , "full-chart-install.yaml" ))
138- Expect (manifests ).To (MatchYAML (string (fullChartInstall )))
138+ Expect (manifests ).To (Equal (string (fullChartInstall )))
139139 })
140140
141141 It ("should not deploy providers when none specified" , func () {
@@ -158,7 +158,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
158158 Expect (manifests ).ToNot (BeEmpty ())
159159 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "all-providers-custom-ns-versions.yaml" ))
160160 Expect (err ).ToNot (HaveOccurred ())
161- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
161+ Expect (manifests ).To (Equal (string (expectedManifests )))
162162 })
163163
164164 It ("should deploy all providers with custom versions" , func () {
@@ -175,7 +175,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
175175 Expect (manifests ).ToNot (BeEmpty ())
176176 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "all-providers-custom-versions.yaml" ))
177177 Expect (err ).ToNot (HaveOccurred ())
178- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
178+ Expect (manifests ).To (Equal (string (expectedManifests )))
179179 })
180180
181181 It ("should deploy all providers with latest version" , func () {
@@ -192,7 +192,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
192192 Expect (manifests ).ToNot (BeEmpty ())
193193 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "all-providers-latest-versions.yaml" ))
194194 Expect (err ).ToNot (HaveOccurred ())
195- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
195+ Expect (manifests ).To (Equal (string (expectedManifests )))
196196 })
197197
198198 It ("should deploy core, bootstrap, control plane when only infra is specified" , func () {
@@ -205,7 +205,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
205205 Expect (manifests ).ToNot (BeEmpty ())
206206 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "only-infra.yaml" ))
207207 Expect (err ).ToNot (HaveOccurred ())
208- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
208+ Expect (manifests ).To (Equal (string (expectedManifests )))
209209 })
210210
211211 It ("should deploy core when only bootstrap is specified" , func () {
@@ -218,7 +218,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
218218 Expect (manifests ).ToNot (BeEmpty ())
219219 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "only-bootstrap.yaml" ))
220220 Expect (err ).ToNot (HaveOccurred ())
221- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
221+ Expect (manifests ).To (Equal (string (expectedManifests )))
222222 })
223223
224224 It ("should deploy core when only control plane is specified" , func () {
@@ -231,7 +231,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
231231 Expect (manifests ).ToNot (BeEmpty ())
232232 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "only-control-plane.yaml" ))
233233 Expect (err ).ToNot (HaveOccurred ())
234- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
234+ Expect (manifests ).To (Equal (string (expectedManifests )))
235235 })
236236
237237 It ("should deploy multiple infra providers with custom namespace and versions" , func () {
@@ -244,7 +244,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
244244 Expect (manifests ).ToNot (BeEmpty ())
245245 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "multiple-infra-custom-ns-versions.yaml" ))
246246 Expect (err ).ToNot (HaveOccurred ())
247- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
247+ Expect (manifests ).To (Equal (string (expectedManifests )))
248248 })
249249
250250 It ("should deploy multiple control plane providers with custom namespace and versions" , func () {
@@ -257,7 +257,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
257257 Expect (manifests ).ToNot (BeEmpty ())
258258 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "multiple-control-plane-custom-ns-versions.yaml" ))
259259 Expect (err ).ToNot (HaveOccurred ())
260- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
260+ Expect (manifests ).To (Equal (string (expectedManifests )))
261261 })
262262
263263 It ("should deploy multiple bootstrap providers with custom namespace and versions" , func () {
@@ -270,7 +270,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
270270 Expect (manifests ).ToNot (BeEmpty ())
271271 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "multiple-bootstrap-custom-ns-versions.yaml" ))
272272 Expect (err ).ToNot (HaveOccurred ())
273- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
273+ Expect (manifests ).To (Equal (string (expectedManifests )))
274274 })
275275
276276 It ("should deploy core when only addon is specified" , func () {
@@ -283,7 +283,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
283283 Expect (manifests ).ToNot (BeEmpty ())
284284 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "only-addon.yaml" ))
285285 Expect (err ).ToNot (HaveOccurred ())
286- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
286+ Expect (manifests ).To (Equal (string (expectedManifests )))
287287 })
288288
289289 It ("should deploy core, bootstrap, control plane when only infra and addon is specified" , func () {
@@ -297,7 +297,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
297297 Expect (manifests ).ToNot (BeEmpty ())
298298 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "only-infra-and-addon.yaml" ))
299299 Expect (err ).ToNot (HaveOccurred ())
300- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
300+ Expect (manifests ).To (Equal (string (expectedManifests )))
301301 })
302302 It ("should deploy core and infra with feature gates enabled" , func () {
303303 manifests , err := helmChart .Run (map [string ]string {
@@ -320,23 +320,23 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
320320 Expect (manifests ).ToNot (BeEmpty ())
321321 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "feature-gates.yaml" ))
322322 Expect (err ).ToNot (HaveOccurred ())
323- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
323+ Expect (manifests ).To (Equal (string (expectedManifests )))
324324 })
325325 It ("should deploy all providers with manager defined but no feature gates enabled" , func () {
326326 manifests , err := helmChart .Run (map [string ]string {
327327 "configSecret.name" : "test-secret-name" ,
328328 "configSecret.namespace" : "test-secret-namespace" ,
329+ "core" : "cluster-api" ,
329330 "infrastructure" : "azure" ,
330331 "addon" : "helm" ,
331- "core" : "cluster-api" ,
332332 "manager.cert-manager.enabled" : "false" ,
333333 "manager.cert-manager.installCRDs" : "false" ,
334334 })
335335 Expect (err ).ToNot (HaveOccurred ())
336336 Expect (manifests ).ToNot (BeEmpty ())
337- expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "all-providers-latest-versions .yaml" ))
337+ expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "all-providers-manager-defined-no-feature-gates .yaml" ))
338338 Expect (err ).ToNot (HaveOccurred ())
339- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
339+ Expect (manifests ).To (Equal (string (expectedManifests )))
340340 })
341341 It ("should deploy all providers when manager is defined but another infrastructure spec field is defined" , func () {
342342 manifests , err := helmChart .Run (map [string ]string {
@@ -352,7 +352,7 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
352352 Expect (manifests ).ToNot (BeEmpty ())
353353 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "manager-defined-missing-other-infra-spec.yaml" ))
354354 Expect (err ).ToNot (HaveOccurred ())
355- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
355+ Expect (manifests ).To (Equal (string (expectedManifests )))
356356 })
357357 It ("should deploy kubeadm control plane with manager specified" , func () {
358358 manifests , err := helmChart .Run (map [string ]string {
@@ -368,6 +368,6 @@ var _ = Describe("Create a proper set of manifests when using helm charts", func
368368 Expect (manifests ).ToNot (BeEmpty ())
369369 expectedManifests , err := os .ReadFile (filepath .Join (customManifestsFolder , "kubeadm-manager-defined.yaml" ))
370370 Expect (err ).ToNot (HaveOccurred ())
371- Expect (manifests ).To (MatchYAML (string (expectedManifests )))
371+ Expect (manifests ).To (Equal (string (expectedManifests )))
372372 })
373373})
0 commit comments