diff --git a/samples/FontIDHyphen.pdf b/samples/FontIDHyphen.pdf deleted file mode 100644 index f111f60f..00000000 Binary files a/samples/FontIDHyphen.pdf and /dev/null differ diff --git a/tests/PHPUnit/Integration/PDFObjectTest.php b/tests/PHPUnit/Integration/PDFObjectTest.php index 1fc113b1..ab7b229b 100644 --- a/tests/PHPUnit/Integration/PDFObjectTest.php +++ b/tests/PHPUnit/Integration/PDFObjectTest.php @@ -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']); } }