mirror of
https://github.com/PHPOffice/PhpSpreadsheet.git
synced 2026-09-17 05:26:45 +00:00
Upgrade Dompdf to 8.4-Compatible Version
This commit is contained in:
Generated
+6
-6
@@ -788,16 +788,16 @@
|
||||
},
|
||||
{
|
||||
"name": "dompdf/dompdf",
|
||||
"version": "v3.0.0",
|
||||
"version": "v3.0.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/dompdf/dompdf.git",
|
||||
"reference": "fbc7c5ee5d94f7a910b78b43feb7931b7f971b59"
|
||||
"reference": "2d622faf9aa1f8f7f24dd094e49b5cf6c0c5d4e6"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/dompdf/dompdf/zipball/fbc7c5ee5d94f7a910b78b43feb7931b7f971b59",
|
||||
"reference": "fbc7c5ee5d94f7a910b78b43feb7931b7f971b59",
|
||||
"url": "https://api.github.com/repos/dompdf/dompdf/zipball/2d622faf9aa1f8f7f24dd094e49b5cf6c0c5d4e6",
|
||||
"reference": "2d622faf9aa1f8f7f24dd094e49b5cf6c0c5d4e6",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -846,9 +846,9 @@
|
||||
"homepage": "https://github.com/dompdf/dompdf",
|
||||
"support": {
|
||||
"issues": "https://github.com/dompdf/dompdf/issues",
|
||||
"source": "https://github.com/dompdf/dompdf/tree/v3.0.0"
|
||||
"source": "https://github.com/dompdf/dompdf/tree/v3.0.1"
|
||||
},
|
||||
"time": "2024-04-29T14:01:28+00:00"
|
||||
"time": "2024-12-05T14:59:38+00:00"
|
||||
},
|
||||
{
|
||||
"name": "dompdf/php-font-lib",
|
||||
|
||||
@@ -9,7 +9,6 @@ use PhpOffice\PhpSpreadsheet\Settings;
|
||||
use PhpOffice\PhpSpreadsheet\Spreadsheet;
|
||||
use PhpOffice\PhpSpreadsheet\Worksheet\Worksheet;
|
||||
use PhpOffice\PhpSpreadsheet\Writer\IWriter;
|
||||
use PhpOffice\PhpSpreadsheet\Writer\Pdf\Dompdf;
|
||||
use RecursiveDirectoryIterator;
|
||||
use RecursiveIteratorIterator;
|
||||
use RecursiveRegexIterator;
|
||||
@@ -129,11 +128,7 @@ class Sample
|
||||
$writerCallback($writer);
|
||||
}
|
||||
$callStartTime = microtime(true);
|
||||
if (PHP_VERSION_ID >= 80400 && $writer instanceof Dompdf) {
|
||||
@$writer->save($path);
|
||||
} else {
|
||||
$writer->save($path);
|
||||
}
|
||||
$writer->save($path);
|
||||
$this->logWrite($writer, $path, $callStartTime);
|
||||
if ($this->isCli() === false) {
|
||||
// @codeCoverageIgnoreStart
|
||||
|
||||
@@ -8,12 +8,6 @@ use PhpOffice\PhpSpreadsheet\IOFactory;
|
||||
use PhpOffice\PhpSpreadsheet\Spreadsheet;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
/**
|
||||
* Not clear that Dompdf will be Php8.4 compatible in time.
|
||||
* Run in separate process and add version test till it is ready.
|
||||
*
|
||||
* @runTestsInSeparateProcesses
|
||||
*/
|
||||
class StreamTest extends TestCase
|
||||
{
|
||||
public static function providerFormats(): array
|
||||
@@ -48,11 +42,7 @@ class StreamTest extends TestCase
|
||||
} else {
|
||||
self::assertSame(0, $stat['size']);
|
||||
|
||||
if ($format === 'Dompdf' && PHP_VERSION_ID >= 80400) {
|
||||
@$writer->save($stream);
|
||||
} else {
|
||||
$writer->save($stream);
|
||||
}
|
||||
$writer->save($stream);
|
||||
|
||||
self::assertIsResource($stream, 'should not close the stream for further usage out of PhpSpreadsheet');
|
||||
$stat = fstat($stream);
|
||||
|
||||
@@ -10,12 +10,6 @@ use PhpOffice\PhpSpreadsheet\Worksheet\PageSetup;
|
||||
use PhpOffice\PhpSpreadsheet\Writer\Pdf\Dompdf;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
/**
|
||||
* Not clear that Dompdf will be Php8.4 compatible in time.
|
||||
* Run in separate process and add version test till it is ready.
|
||||
*
|
||||
* @runTestsInSeparateProcesses
|
||||
*/
|
||||
class PaperSizeArrayTest extends TestCase
|
||||
{
|
||||
private string $outfile = '';
|
||||
@@ -42,11 +36,7 @@ class PaperSizeArrayTest extends TestCase
|
||||
$sheet->setCellValue('A7', 'Lorem Ipsum');
|
||||
$writer = new Dompdf($spreadsheet);
|
||||
$this->outfile = File::temporaryFilename();
|
||||
if (PHP_VERSION_ID >= 80400) { // hopefully temporary
|
||||
@$writer->save($this->outfile);
|
||||
} else {
|
||||
$writer->save($this->outfile);
|
||||
}
|
||||
$writer->save($this->outfile);
|
||||
$spreadsheet->disconnectWorksheets();
|
||||
unset($spreadsheet);
|
||||
$contents = file_get_contents($this->outfile);
|
||||
@@ -66,11 +56,7 @@ class PaperSizeArrayTest extends TestCase
|
||||
$sheet->setCellValue('A7', 'Lorem Ipsum');
|
||||
$writer = new Dompdf($spreadsheet);
|
||||
$this->outfile = File::temporaryFilename();
|
||||
if (PHP_VERSION_ID >= 80400) { // hopefully temporary
|
||||
@$writer->save($this->outfile);
|
||||
} else {
|
||||
$writer->save($this->outfile);
|
||||
}
|
||||
$writer->save($this->outfile);
|
||||
$spreadsheet->disconnectWorksheets();
|
||||
unset($spreadsheet);
|
||||
$contents = file_get_contents($this->outfile);
|
||||
|
||||
Reference in New Issue
Block a user