Merge pull request #9251 from tonistiigi/use-format-logging-functions

Fix misuses of format based logging functions
This commit is contained in:
Jessie Frazelle 2014-11-19 15:25:42 -08:00
commit eb3bbde6d1
4 changed files with 4 additions and 4 deletions

View File

@ -33,7 +33,7 @@ func newDriver(t *testing.T, name string) *Driver {
d, err := graphdriver.GetDriver(name, root, nil) d, err := graphdriver.GetDriver(name, root, nil)
if err != nil { if err != nil {
if err == graphdriver.ErrNotSupported || err == graphdriver.ErrPrerequisites { if err == graphdriver.ErrNotSupported || err == graphdriver.ErrPrerequisites {
t.Skip("Driver %s not supported", name) t.Skipf("Driver %s not supported", name)
} }
t.Fatal(err) t.Fatal(err)
} }

View File

@ -112,7 +112,7 @@ func StoreImage(img *Image, layerData archive.ArchiveReader, root string) error
checksum := layerTarSum.Sum(nil) checksum := layerTarSum.Sum(nil)
if img.Checksum != "" && img.Checksum != checksum { if img.Checksum != "" && img.Checksum != checksum {
log.Warn("image layer checksum mismatch: computed %q, expected %q", checksum, img.Checksum) log.Warnf("image layer checksum mismatch: computed %q, expected %q", checksum, img.Checksum)
} }
img.Checksum = checksum img.Checksum = checksum

View File

@ -232,7 +232,7 @@ func TestEventsImagePull(t *testing.T) {
since := time.Now().Unix() since := time.Now().Unix()
pullCmd := exec.Command(dockerBinary, "pull", "scratch") pullCmd := exec.Command(dockerBinary, "pull", "scratch")
if out, _, err := runCommandWithOutput(pullCmd); err != nil { if out, _, err := runCommandWithOutput(pullCmd); err != nil {
t.Fatal("pulling the scratch image from has failed: %s, %v", out, err) t.Fatalf("pulling the scratch image from has failed: %s, %v", out, err)
} }
eventsCmd := exec.Command(dockerBinary, "events", eventsCmd := exec.Command(dockerBinary, "events",

View File

@ -11,7 +11,7 @@ import (
func TestNetworkNat(t *testing.T) { func TestNetworkNat(t *testing.T) {
iface, err := net.InterfaceByName("eth0") iface, err := net.InterfaceByName("eth0")
if err != nil { if err != nil {
t.Skip("Test not running with `make test`. Interface eth0 not found: %s", err) t.Skipf("Test not running with `make test`. Interface eth0 not found: %s", err)
} }
ifaceAddrs, err := iface.Addrs() ifaceAddrs, err := iface.Addrs()