Skip to content

Commit 66e6cc3

Browse files
committed
Fix golint warnings
Signed-off-by: Lei Jitang <[email protected]>
1 parent f95665c commit 66e6cc3

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

image/layer_test.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,7 @@ func TestCreateFilesystemChangeset(t *testing.T) {
9292
}
9393
modifiedfiles := map[string]func(string) error{
9494
"bin/app": func(path string) error {
95-
err := ioutil.WriteFile(path, []byte(fmt.Sprintf("Hello world")), 0755)
96-
return err
95+
return ioutil.WriteFile(path, []byte(fmt.Sprintf("Hello world")), 0755)
9796
},
9897
}
9998

@@ -175,13 +174,13 @@ func createFilesystem(path string, files map[string]bool, modify map[string]func
175174
}
176175

177176
func verify(m1 map[string]bool, m2 map[string]bool) error {
178-
for f, _ := range m1 {
177+
for f := range m1 {
179178
if _, ok := m2[f]; !ok {
180179
return fmt.Errorf("expected file %v not exist", f)
181180
}
182181
}
183182

184-
for f, _ := range m2 {
183+
for f := range m2 {
185184
if _, ok := m1[f]; !ok {
186185
return fmt.Errorf("%v is not an expected file", f)
187186
}

0 commit comments

Comments
 (0)