Skip to content

Commit

Permalink
Remove test case PDF
Browse files Browse the repository at this point in the history
Remove the Font ID with hyphen test case PDF as we could not contact the submitter to get permission to use it.
Change the unit test to directly test if a Font ID with a hyphen is correctly parsed.
  • Loading branch information
GreyWyvern committed Jul 18, 2023
1 parent dea98d1 commit d7a378f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Binary file removed samples/FontIDHyphen.pdf
Binary file not shown.
10 changes: 5 additions & 5 deletions tests/PHPUnit/Integration/PDFObjectTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -282,12 +282,12 @@ public function testImproperFontFallback(): void
*/
public function testFontIDWithHyphen(): void
{
$filename = $this->rootDir.'/samples/FontIDHyphen.pdf';
$pdfObject = $this->getPdfObjectInstance(new Document());

$parser = $this->getParserInstance();
$document = $parser->parseFile($filename);
$pages = $document->getPages();
$fontCommandHyphen = $pdfObject->getCommandsText('/FID-01 15.00 Tf');

$this->assertStringContainsString('AERODROME', $pages[0]->getText());
$this->assertEquals('/', $fontCommandHyphen[0]['t']);
$this->assertEquals('Tf', $fontCommandHyphen[0]['o']);
$this->assertEquals('FID-01 15.00', $fontCommandHyphen[0]['c']);
}
}

0 comments on commit d7a378f

Please sign in to comment.