mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-01-12 02:08:40 +00:00
39 lines
863 B
PHP
39 lines
863 B
PHP
<?php
|
|
/**
|
|
* Jingga
|
|
*
|
|
* PHP Version 8.2
|
|
*
|
|
* @package tests
|
|
* @copyright Dennis Eichhorn
|
|
* @license OMS License 2.0
|
|
* @version 1.0.0
|
|
* @link https://jingga.app
|
|
*/
|
|
declare(strict_types=1);
|
|
|
|
namespace phpOMS\tests\Utils\Parser\Presentation;
|
|
|
|
include_once __DIR__ . '/../../../Autoloader.php';
|
|
|
|
use PhpOffice\PhpPresentation\IOFactory;
|
|
use phpOMS\Utils\Parser\Presentation\PresentationWriter;
|
|
|
|
/**
|
|
* @internal
|
|
*/
|
|
final class PresentationWriterTest extends \PHPUnit\Framework\TestCase
|
|
{
|
|
public function testParsing() : void
|
|
{
|
|
$presentation = IOFactory::load(__DIR__ . '/data/Powerpoint.pptx');
|
|
|
|
$writer = new PresentationWriter($presentation);
|
|
|
|
self::assertTrue(
|
|
\abs(\strlen(\file_get_contents(__DIR__ . '/data/Powerpoint.html'))
|
|
- \strlen($writer->renderHtml())) < 100
|
|
);
|
|
}
|
|
}
|