Skip to content

Commit

Permalink
Fixed typo in TestCase method
Browse files Browse the repository at this point in the history
  • Loading branch information
HorstOeko committed Oct 22, 2024
1 parent c025d0c commit 31877c6
Show file tree
Hide file tree
Showing 22 changed files with 91 additions and 91 deletions.
2 changes: 1 addition & 1 deletion tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ public function getPrivateMethodFromObject(object $object, string $methodName):
* @param array $args
* @return mixed
*/
public function invokePivateMethodFromObject($object, string $methodName, ...$args)
public function invokePrivateMethodFromObject($object, string $methodName, ...$args)
{
$method = $this->getPrivateMethodFromObject($object, $methodName);
return $method->invoke($object, ...$args);
Expand Down
12 changes: 6 additions & 6 deletions tests/testcases/BuilderEn16931Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ public function testDocumentProfile(): void

public function testDocumentGetters(): void
{
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePrivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertEquals('en16931', self::$document->getProfileDefinitionParameter('name'));
$this->assertEquals('EN 16931 (COMFORT)', self::$document->getProfileDefinitionParameter('altname'));
$this->assertEquals('urn:cen.eu:en16931:2017', self::$document->getProfileDefinitionParameter('contextparameter'));
Expand Down
12 changes: 6 additions & 6 deletions tests/testcases/BuilderExtendedTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ public function testDocumentProfile(): void

public function testDocumentGetters(): void
{
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\extended\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\extended\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePrivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertEquals('extended', self::$document->getProfileDefinitionParameter('name'));
$this->assertEquals('EXTENDED', self::$document->getProfileDefinitionParameter('altname'));
$this->assertEquals('urn:cen.eu:en16931:2017#conformant#urn:factur-x.eu:1p0:extended', self::$document->getProfileDefinitionParameter('contextparameter'));
Expand Down
12 changes: 6 additions & 6 deletions tests/testcases/BuilderMinimumTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ public function testDocumentProfile(): void

public function testDocumentGetters(): void
{
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\minimum\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\minimum\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePrivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertEquals('minimum', self::$document->getProfileDefinitionParameter('name'));
$this->assertEquals('MINIMUM', self::$document->getProfileDefinitionParameter('altname'));
$this->assertEquals('urn:factur-x.eu:1p0:minimum', self::$document->getProfileDefinitionParameter('contextparameter'));
Expand Down
12 changes: 6 additions & 6 deletions tests/testcases/DocumentTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,12 @@ public function testDocumentGetters(): void
{
$doc = ZugferdDocumentBuilder::createNew(ZugferdProfiles::PROFILE_EXTENDED);

$this->assertNotNull($this->invokePivateMethodFromObject($doc, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\extended\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject($doc, 'getInvoiceObject')));
$this->assertNotNull($this->invokePivateMethodFromObject($doc, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePivateMethodFromObject($doc, 'getSerializer')));
$this->assertNotNull($this->invokePivateMethodFromObject($doc, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePivateMethodFromObject($doc, 'getObjectHelper')));
$this->assertNotNull($this->invokePrivateMethodFromObject($doc, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\extended\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject($doc, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject($doc, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePrivateMethodFromObject($doc, 'getSerializer')));
$this->assertNotNull($this->invokePrivateMethodFromObject($doc, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePrivateMethodFromObject($doc, 'getObjectHelper')));
}

/**
Expand Down
4 changes: 2 additions & 2 deletions tests/testcases/PdfReaderEn16931AllowanceChargeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ public function testDocumentGenerals(): void
$this->assertEquals("", $documentname);
$this->assertEquals("", $documentlanguage);
$this->assertNull($effectiveSpecifiedPeriod);
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
}

public function testDocumentNotes(): void
Expand Down
4 changes: 2 additions & 2 deletions tests/testcases/PdfReaderEn16931Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ public function testDocumentGenerals(): void
$this->assertEquals("", $documentname);
$this->assertEquals("", $documentlanguage);
$this->assertNull($effectiveSpecifiedPeriod);
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
}

public function testDocumentNotes(): void
Expand Down
4 changes: 2 additions & 2 deletions tests/testcases/PdfReaderExtended2Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ public function testDocumentGenerals(): void
$this->assertEquals("", $documentname);
$this->assertEquals("", $documentlanguage);
$this->assertNull($effectiveSpecifiedPeriod);
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\extended\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\extended\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
}

public function testDocumentNotes(): void
Expand Down
4 changes: 2 additions & 2 deletions tests/testcases/PdfReaderExtendedTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ public function testDocumentGenerals(): void
$this->assertEquals("KOSTENRECHNUNG", $documentname);
$this->assertEquals("", $documentlanguage);
$this->assertNull($effectiveSpecifiedPeriod);
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\extended\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\extended\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
}

public function testDocumentNotes(): void
Expand Down
4 changes: 2 additions & 2 deletions tests/testcases/PdfReaderMinimumTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ public function testDocumentGenerals(): void
$this->assertEquals("", $documentname);
$this->assertEquals("", $documentlanguage);
$this->assertNull($effectiveSpecifiedPeriod);
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\minimum\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\minimum\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
}

public function testDocumentNotes(): void
Expand Down
4 changes: 2 additions & 2 deletions tests/testcases/PdfReaderMultipleAttachmentsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public function testDocumentGenerals(): void
$this->assertEquals("", $documentname);
$this->assertEquals("", $documentlanguage);
$this->assertNull($effectiveSpecifiedPeriod);
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
}
}
4 changes: 2 additions & 2 deletions tests/testcases/PdfReaderXRechnungTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ public function testDocumentGenerals(): void
$this->assertEquals("", $documentname);
$this->assertEquals("", $documentlanguage);
$this->assertNull($effectiveSpecifiedPeriod);
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
}

public function testDocumentNotes(): void
Expand Down
12 changes: 6 additions & 6 deletions tests/testcases/ReaderBasicTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ public function testDocumentProfile(): void

public function testDocumentGetters(): void
{
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\basic\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\basic\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePrivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertEquals('basic', self::$document->getProfileDefinitionParameter('name'));
$this->assertEquals('BASIC', self::$document->getProfileDefinitionParameter('altname'));
$this->assertEquals('urn:cen.eu:en16931:2017#compliant#urn:factur-x.eu:1p0:basic', self::$document->getProfileDefinitionParameter('contextparameter'));
Expand Down
12 changes: 6 additions & 6 deletions tests/testcases/ReaderEn16931AllowanceChargeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ public function testDocumentProfile(): void

public function testDocumentGetters(): void
{
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePrivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertEquals('en16931', self::$document->getProfileDefinitionParameter('name'));
$this->assertEquals('EN 16931 (COMFORT)', self::$document->getProfileDefinitionParameter('altname'));
$this->assertEquals('urn:cen.eu:en16931:2017', self::$document->getProfileDefinitionParameter('contextparameter'));
Expand Down
12 changes: 6 additions & 6 deletions tests/testcases/ReaderEn16931Bank1Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,12 @@ public function testDocumentProfile(): void

public function testDocumentGetters(): void
{
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject'));
$this->assertEquals('horstoeko\zugferd\entities\en16931\rsm\CrossIndustryInvoice', get_class($this->invokePrivateMethodFromObject(self::$document, 'getInvoiceObject')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getSerializer'));
$this->assertEquals('JMS\Serializer\Serializer', get_class($this->invokePrivateMethodFromObject(self::$document, 'getSerializer')));
$this->assertNotNull($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper'));
$this->assertEquals('horstoeko\zugferd\ZugferdObjectHelper', get_class($this->invokePrivateMethodFromObject(self::$document, 'getObjectHelper')));
$this->assertEquals('en16931', self::$document->getProfileDefinitionParameter('name'));
$this->assertEquals('EN 16931 (COMFORT)', self::$document->getProfileDefinitionParameter('altname'));
$this->assertEquals('urn:cen.eu:en16931:2017', self::$document->getProfileDefinitionParameter('contextparameter'));
Expand Down
Loading

0 comments on commit 31877c6

Please sign in to comment.