mirror of
https://github.com/gotenberg/gotenberg.git
synced 2026-08-13 19:02:15 +01:00
fix(libreoffice): keep original extension all the time for preserved filenames in zipped output
This commit is contained in:
@@ -190,11 +190,15 @@ func TestContext_GeneratePath(t *testing.T) {
|
||||
dirPath: "/foo",
|
||||
}
|
||||
|
||||
path := ctx.GeneratePath(".pdf")
|
||||
|
||||
path := ctx.GeneratePath("", ".pdf")
|
||||
if !strings.HasPrefix(path, ctx.dirPath) {
|
||||
t.Errorf("expected '%s' to start with '%s'", path, ctx.dirPath)
|
||||
}
|
||||
|
||||
path = ctx.GeneratePath("foo.txt", ".pdf")
|
||||
if !strings.Contains(path, "foo.txt.pdf") {
|
||||
t.Errorf("expected '%s' to start with '%s'", path, ctx.dirPath)
|
||||
}
|
||||
}
|
||||
|
||||
func TestContext_AddOutputPaths(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user