feat(pdfengines): add PDF/UA (#714)

This commit is contained in:
Julien Neuhart
2023-11-05 20:14:36 +01:00
committed by GitHub
parent 9c3dfc78df
commit 143b7ce678
39 changed files with 1300 additions and 1013 deletions

View File

@@ -94,7 +94,7 @@ func TestLibreOffice_Provision(t *testing.T) {
mod := &struct {
gotenberg.ModuleMock
libreofficeapi.ProviderMock
gotenberg.PDFEngineProviderMock
gotenberg.PdfEngineProviderMock
}{}
mod.DescriptorMock = func() gotenberg.ModuleDescriptor {
return gotenberg.ModuleDescriptor{ID: "bar", New: func() gotenberg.Module { return mod }}
@@ -102,7 +102,7 @@ func TestLibreOffice_Provision(t *testing.T) {
mod.LibreOfficeMock = func() (libreofficeapi.Uno, error) {
return new(libreofficeapi.ApiMock), nil
}
mod.PDFEngineMock = func() (gotenberg.PDFEngine, error) {
mod.PdfEngineMock = func() (gotenberg.PdfEngine, error) {
return nil, errors.New("foo")
}
@@ -123,7 +123,7 @@ func TestLibreOffice_Provision(t *testing.T) {
mod := &struct {
gotenberg.ModuleMock
libreofficeapi.ProviderMock
gotenberg.PDFEngineProviderMock
gotenberg.PdfEngineProviderMock
}{}
mod.DescriptorMock = func() gotenberg.ModuleDescriptor {
return gotenberg.ModuleDescriptor{ID: "bar", New: func() gotenberg.Module { return mod }}
@@ -131,8 +131,8 @@ func TestLibreOffice_Provision(t *testing.T) {
mod.LibreOfficeMock = func() (libreofficeapi.Uno, error) {
return new(libreofficeapi.ApiMock), nil
}
mod.PDFEngineMock = func() (gotenberg.PDFEngine, error) {
return new(gotenberg.PDFEngineMock), nil
mod.PdfEngineMock = func() (gotenberg.PdfEngine, error) {
return new(gotenberg.PdfEngineMock), nil
}
return gotenberg.NewContext(