Commit c4a177bd authored by Matthew Holt's avatar Matthew Holt

Fix lint warnings and update CI tests to Go 1.7.1

parent 8ecd5435
...@@ -2,7 +2,7 @@ language: go ...@@ -2,7 +2,7 @@ language: go
go: go:
- 1.6.3 - 1.6.3
- 1.7 - 1.7.1
- tip - tip
matrix: matrix:
......
...@@ -275,33 +275,33 @@ func TestRecursiveImport(t *testing.T) { ...@@ -275,33 +275,33 @@ func TestRecursiveImport(t *testing.T) {
return true return true
} }
recursive_file1, err := filepath.Abs("testdata/recursive_import_test1") recursiveFile1, err := filepath.Abs("testdata/recursive_import_test1")
if err != nil { if err != nil {
t.Fatal(err) t.Fatal(err)
} }
recursive_file2, err := filepath.Abs("testdata/recursive_import_test2") recursiveFile2, err := filepath.Abs("testdata/recursive_import_test2")
if err != nil { if err != nil {
t.Fatal(err) t.Fatal(err)
} }
// test relative recursive import // test relative recursive import
err = ioutil.WriteFile(recursive_file1, []byte( err = ioutil.WriteFile(recursiveFile1, []byte(
`localhost `localhost
dir1 dir1
import recursive_import_test2`), 0644) import recursive_import_test2`), 0644)
if err != nil { if err != nil {
t.Fatal(err) t.Fatal(err)
} }
defer os.Remove(recursive_file1) defer os.Remove(recursiveFile1)
err = ioutil.WriteFile(recursive_file2, []byte("dir2 1"), 0644) err = ioutil.WriteFile(recursiveFile2, []byte("dir2 1"), 0644)
if err != nil { if err != nil {
t.Fatal(err) t.Fatal(err)
} }
defer os.Remove(recursive_file2) defer os.Remove(recursiveFile2)
// import absolute path // import absolute path
result, err := testParseOne("import " + recursive_file1) result, err := testParseOne("import " + recursiveFile1)
if err != nil { if err != nil {
t.Fatal(err) t.Fatal(err)
} }
...@@ -319,16 +319,16 @@ func TestRecursiveImport(t *testing.T) { ...@@ -319,16 +319,16 @@ func TestRecursiveImport(t *testing.T) {
} }
// test absolute recursive import // test absolute recursive import
err = ioutil.WriteFile(recursive_file1, []byte( err = ioutil.WriteFile(recursiveFile1, []byte(
`localhost `localhost
dir1 dir1
import `+recursive_file2), 0644) import `+recursiveFile2), 0644)
if err != nil { if err != nil {
t.Fatal(err) t.Fatal(err)
} }
// import absolute path // import absolute path
result, err = testParseOne("import " + recursive_file1) result, err = testParseOne("import " + recursiveFile1)
if err != nil { if err != nil {
t.Fatal(err) t.Fatal(err)
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment