Metadata: Add tests to pkg/txt/file_title_test.go
Signed-off-by: Michael Mayer <michael@photoprism.app>
This commit is contained in:
parent
7ec6b7e66f
commit
fe182d78f4
1 changed files with 6 additions and 0 deletions
|
@ -40,6 +40,12 @@ func TestFileTitle(t *testing.T) {
|
||||||
t.Run("IMG_4568", func(t *testing.T) {
|
t.Run("IMG_4568", func(t *testing.T) {
|
||||||
assert.Equal(t, "", FileTitle("IMG_4568"))
|
assert.Equal(t, "", FileTitle("IMG_4568"))
|
||||||
})
|
})
|
||||||
|
t.Run("mr-kitty_life.svg", func(t *testing.T) {
|
||||||
|
assert.Equal(t, "Mr Kitty Life", FileTitle("mr-kitty_life.svg"))
|
||||||
|
})
|
||||||
|
t.Run("mr-kitty--life.svg", func(t *testing.T) {
|
||||||
|
assert.Equal(t, "Mr Kitty / Life", FileTitle("mr-kitty--life.svg"))
|
||||||
|
})
|
||||||
t.Run("queen-city-yacht-club--toronto-island_7999432607_o.jpg", func(t *testing.T) {
|
t.Run("queen-city-yacht-club--toronto-island_7999432607_o.jpg", func(t *testing.T) {
|
||||||
assert.Equal(t, "Queen City Yacht Club / Toronto Island", FileTitle("queen-city-yacht-club--toronto-island_7999432607_o.jpg"))
|
assert.Equal(t, "Queen City Yacht Club / Toronto Island", FileTitle("queen-city-yacht-club--toronto-island_7999432607_o.jpg"))
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue