diff --git a/internal/config/config_test.go b/internal/config/config_test.go index 75e1b1d3e..073bb1756 100644 --- a/internal/config/config_test.go +++ b/internal/config/config_test.go @@ -36,7 +36,7 @@ func TestConfig_Version(t *testing.T) { c := NewConfig(ctx) version := c.Version() - assert.Equal(t, "1.0.0", version) + assert.Equal(t, "test", version) } func TestConfig_TensorFlowVersion(t *testing.T) { diff --git a/internal/config/test.go b/internal/config/test.go index ac31bc0f6..e0bde57cb 100644 --- a/internal/config/test.go +++ b/internal/config/test.go @@ -144,7 +144,7 @@ func CliTestContext() *cli.Context { globalSet.Bool("detect-nsfw", config.DetectNSFW, "doc") app := cli.NewApp() - app.Version = "1.0.0" + app.Version = "test" c := cli.NewContext(app, globalSet, nil) diff --git a/pkg/fs/filetype_test.go b/pkg/fs/filetype_test.go index 3bfefcc49..f228c68f6 100644 --- a/pkg/fs/filetype_test.go +++ b/pkg/fs/filetype_test.go @@ -43,12 +43,12 @@ func TestFileType_Find(t *testing.T) { result := TypeJpeg.Find("testdata/test (2).xmp", true) assert.Equal(t, "testdata/test.jpg", result) }) - t.Run("prefixUpper", func(t *testing.T) { - result := TypeJpeg.Find("testdata/catyellow.xmp", true) + t.Run("name upper", func(t *testing.T) { + result := TypeJpeg.Find("testdata/CATYELLOW.xmp", true) assert.Equal(t, "testdata/CATYELLOW.jpg", result) }) - t.Run("prefixLower", func(t *testing.T) { - result := TypeJpeg.Find("testdata/CHAMELEON_LIME.xmp", true) + t.Run("name lower", func(t *testing.T) { + result := TypeJpeg.Find("testdata/chameleon_lime.xmp", true) assert.Equal(t, "testdata/chameleon_lime.jpg", result) }) } diff --git a/pkg/txt/resources/stopwords.txt b/pkg/txt/resources/stopwords.txt index a260a8f3e..6d4e05deb 100644 --- a/pkg/txt/resources/stopwords.txt +++ b/pkg/txt/resources/stopwords.txt @@ -12,6 +12,8 @@ photos import export abc +val +tmp xyz jpg jpeg diff --git a/pkg/txt/stopwords.go b/pkg/txt/stopwords.go index 93a679a84..f09925917 100644 --- a/pkg/txt/stopwords.go +++ b/pkg/txt/stopwords.go @@ -17,6 +17,8 @@ var Stopwords = map[string]bool{ "import": true, "export": true, "abc": true, + "val": true, + "tmp": true, "xyz": true, "jpg": true, "jpeg": true,