trim normalized file extension

This commit is contained in:
Gani Georgiev
2025-12-12 08:49:10 +02:00
parent 4399a6c1ab
commit 7286f34104
4 changed files with 12 additions and 6 deletions

View File

@@ -211,6 +211,8 @@ func TestFileNameNormalizations(t *testing.T) {
{".png", `^\w{10}_\w{10}\.png$`},
{".tar.gz", `^\w{10}_\w{10}\.tar\.gz$`},
{"a.tar.gz", `^a\w{10}_\w{10}\.tar\.gz$`},
{"....abc", `^\w{10}_\w{10}\.abc$`},
{"a.b.c.?.?.?.2", `^a_b_c_\w{10}\.2$`},
{"a.b.c.d.tar.gz", `^a_b_c_d_\w{10}\.tar\.gz$`},
{"abcd", `^abcd_\w{10}\.txt$`},
{"a b! c d . 456", `^a_b_c_d_\w{10}\.456$`}, // normalize spaces