From e25db3df2ef3e55b0b0d7b6e9449d008d3a8709c Mon Sep 17 00:00:00 2001 From: Mohd Bilal Date: Sun, 27 Feb 2022 09:11:00 +0000 Subject: [PATCH] Test case updated --- cmd/config/internal/commands/fmt_test.go | 2 +- kyaml/kio/filters/fmtr_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/config/internal/commands/fmt_test.go b/cmd/config/internal/commands/fmt_test.go index 16ba27389..c0918ac4f 100644 --- a/cmd/config/internal/commands/fmt_test.go +++ b/cmd/config/internal/commands/fmt_test.go @@ -164,7 +164,7 @@ func TestCmd_failFileContents(t *testing.T) { err := r.Command.Execute() // expect an error - assert.EqualError(t, err, "yaml: line 1: did not find expected node content") + assert.EqualError(t, err, "MalformedYAMLError: yaml: line 1: did not find expected node content") } func TestFmtSubPackages(t *testing.T) { diff --git a/kyaml/kio/filters/fmtr_test.go b/kyaml/kio/filters/fmtr_test.go index a79e4eb9b..697b1c665 100644 --- a/kyaml/kio/filters/fmtr_test.go +++ b/kyaml/kio/filters/fmtr_test.go @@ -673,7 +673,7 @@ apiVersion: example.com/v1beta1 ` _, err := FormatInput(strings.NewReader(y)) - assert.EqualError(t, err, "yaml: line 15: found character that cannot start any token") + assert.EqualError(t, err, "MalformedYAMLError: yaml: line 15: found character that cannot start any token") } // TestFormatFileOrDirectory_yamlExtFile verifies that FormatFileOrDirectory will format a file