Kaydet (Commit) 14b9e0bf authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Consistently skip "Import the bugdoc and print to PDF" tests

At least some local Linux x86 32-bit build of mine with --disable-cups (which
might or might not be relevant) kept failing the

  CPPUNIT_ASSERT(pPdfDocument);

in the recently added PdfExportTest::testSofthyphenPos, apparently because the
generated temp file (maTempFile) was empty.

But PdfExportTest::testTdf107868 is an older test that already gets skipped if
!pPdfDocument, so make PdfExportTest::testSofthyphenPos be consistently skipped
in the same way (instead of trying to find out why exactly it failed for me).

Change-Id: Ifc1c507fbfb00e32ed3bf94d8d520f9c60d5c4fe
Reviewed-on: https://gerrit.libreoffice.org/67163Reviewed-by: 's avatarMichael Stahl <Michael.Stahl@cib.de>
Tested-by: Jenkins
üst 50cd28e5
......@@ -626,14 +626,13 @@ void PdfExportTest::testSofthyphenPos()
SvFileStream aFile(maTempFile.GetURL(), StreamMode::READ);
SvMemoryStream aMemory;
aMemory.WriteStream(aFile);
if (aFile.bad())
DocumentHolder pPdfDocument(FPDF_LoadMemDocument(aMemory.GetData(), aMemory.GetSize(), /*password=*/nullptr));
if (!pPdfDocument.get())
{
// Printing to PDF failed in a non-interesting way, e.g. CUPS is not
// running, there is no printer defined, etc.
return;
}
DocumentHolder pPdfDocument(FPDF_LoadMemDocument(aMemory.GetData(), aMemory.GetSize(), /*password=*/nullptr));
CPPUNIT_ASSERT(pPdfDocument);
// The document has one page.
CPPUNIT_ASSERT_EQUAL(1, FPDF_GetPageCount(pPdfDocument.get()));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment