Skip to content

[18.09 backport] Fix test for Go 1.12.x - #1734

Merged
silvin-lubecki merged 1 commit into
docker:18.09from
thaJeztah:18.09_backport_fix_test_for_go_1.12
Mar 14, 2019
Merged

[18.09 backport] Fix test for Go 1.12.x#1734
silvin-lubecki merged 1 commit into
docker:18.09from
thaJeztah:18.09_backport_fix_test_for_go_1.12

Conversation

@thaJeztah

Copy link
Copy Markdown
Member

backport of #1712 for 18.09. In preparation of future Go updates

After switching to Go 1.12, the format-string causes an error;

=== Errors
cli/config/config_test.go:154:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:217:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:253:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:288:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:435:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:448:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
DONE 1115 tests, 2 skipped, 6 errors in 215.984s
make: *** [Makefile:22: test-coverage] Error 2
Exited with code 2

Signed-off-by: Sebastiaan van Stijn github@gone.nl
(cherry picked from commit d4877fb)
Signed-off-by: Sebastiaan van Stijn github@gone.nl

- What I did

- How I did it

- How to verify it

- Description for the changelog

- A picture of a cute animal (not mandatory but encouraged)

After switching to Go 1.12, the format-string causes an error;
```
=== Errors
cli/config/config_test.go:154:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:217:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:253:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:288:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:435:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
cli/config/config_test.go:448:3: Fatalf format %q has arg config of wrong type *github.com/docker/cli/cli/config/configfile.ConfigFile
DONE 1115 tests, 2 skipped, 6 errors in 215.984s
make: *** [Makefile:22: test-coverage] Error 2
Exited with code 2
```
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit d4877fb)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
@thaJeztah

Copy link
Copy Markdown
MemberAuthor

ping @silvin-lubecki@vdemeester PTAL

@codecov-io

Copy link
Copy Markdown

Codecov Report

Merging #1734 into 18.09 will not change coverage.
The diff coverage is n/a.

@@ Coverage Diff @@## 18.09 #1734 +/- ##
=======================================
Coverage 54.09% 54.09% =======================================
Files 290 290 Lines 19406 19406 =======================================
Hits 10498 10498 Misses 8236 8236 Partials 672 672

@vdemeestervdemeester left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🐯

@silvin-lubeckisilvin-lubecki left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@silvin-lubecki
silvin-lubecki merged commit 76f4876 into docker:18.09Mar 14, 2019
@thaJeztah
thaJeztah deleted the 18.09_backport_fix_test_for_go_1.12 branch March 14, 2019 16:40
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants

@thaJeztah@codecov-io@vdemeester@silvin-lubecki@GordonTheTurtle