diff options
Diffstat (limited to '')
-rw-r--r-- | reader/reader_test.go | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/reader/reader_test.go b/reader/reader_test.go index 33eea2e..4be02df 100644 --- a/reader/reader_test.go +++ b/reader/reader_test.go @@ -1,6 +1,7 @@ package reader import ( + "strings" "testing" ) @@ -137,8 +138,18 @@ func TestExtract(t *testing.T) { func TestGetTargetFiles(t *testing.T) { path := "/home/lemon/go/src/github.com/hammerheadlemon/datamaps-go/reader/testdata/" - _, err := GetTargetFiles(path) + files, err := GetTargetFiles(path) if err != nil { t.Error(err) } + found := false + for _, f := range files { + if strings.Contains(f, "test_template.xlsx") { + found = true + break + } + } + if found == false { + t.Errorf("test_template.xlsx not found - and it is there!") + } } |