Add tests

This commit is contained in:
Peter Chakalov
2025-01-22 18:07:24 +02:00
parent 2598387b21
commit 820c11c9aa
7 changed files with 110 additions and 1 deletions

View File

@@ -239,6 +239,15 @@ func TestPdfCpu_Split(t *testing.T) {
}
}
func TestPdfCpu_Flatten(t *testing.T) {
mod := new(PdfCpu)
err := mod.Flatten(context.TODO(), zap.NewNop(), "", "")
if !errors.Is(err, gotenberg.ErrPdfEngineMethodNotSupported) {
t.Errorf("expected error %v, but got: %v", gotenberg.ErrPdfEngineMethodNotSupported, err)
}
}
func TestPdfCpu_Convert(t *testing.T) {
mod := new(PdfCpu)
err := mod.Convert(context.TODO(), zap.NewNop(), gotenberg.PdfFormats{}, "", "")