You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
803 B
29 lines
803 B
2 months ago
|
<?php
|
||
|
|
||
|
namespace PhpOffice\PhpSpreadsheetTests\Shared;
|
||
|
|
||
|
use PhpOffice\PhpSpreadsheet\Shared\OLERead;
|
||
|
use PHPUnit\Framework\TestCase;
|
||
|
|
||
|
class OLEReadTest extends TestCase
|
||
|
{
|
||
|
public function testReadOleStreams(): void
|
||
|
{
|
||
|
$dataDir = 'tests/data/Shared/OLERead/';
|
||
|
$ole = new OLERead();
|
||
|
$ole->read('tests/data/Reader/XLS/sample.xls');
|
||
|
self::assertEquals(
|
||
|
file_get_contents($dataDir . 'wrkbook'),
|
||
|
$ole->getStream($ole->wrkbook)
|
||
|
);
|
||
|
self::assertEquals(
|
||
|
file_get_contents($dataDir . 'summary'),
|
||
|
$ole->getStream($ole->summaryInformation)
|
||
|
);
|
||
|
self::assertEquals(
|
||
|
file_get_contents($dataDir . 'document'),
|
||
|
$ole->getStream($ole->documentSummaryInformation)
|
||
|
);
|
||
|
}
|
||
|
}
|