Skip to content

Commit

Permalink
Merge pull request #52 from easybill/crb/test_for_new_fields_v2.3
Browse files Browse the repository at this point in the history
Add tests for BT-89 and BT-90
  • Loading branch information
ChrisB9 authored Jul 13, 2023
2 parents aa7e624 + 19620a4 commit 126f449
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/zugferd211/Tests/BuilderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,7 @@ public function testBuildXRechnungExtendedExample(): void
$invoice->supplyChainTradeTransaction->applicableHeaderTradeDelivery->deliveryNoteReferencedDocument->formattedIssueDateTime = FormattedDateTime::create('102', '20180305');

$invoice->supplyChainTradeTransaction->applicableHeaderTradeSettlement = new HeaderTradeSettlement();
$invoice->supplyChainTradeTransaction->applicableHeaderTradeSettlement->creditorReferenceID = 'TEST1234';
$invoice->supplyChainTradeTransaction->applicableHeaderTradeSettlement->paymentReference = '421102';
$invoice->supplyChainTradeTransaction->applicableHeaderTradeSettlement->currency = 'EUR';
$invoice->supplyChainTradeTransaction->applicableHeaderTradeSettlement->payeeTradeParty = $sellerTradeParty;
Expand Down Expand Up @@ -370,6 +371,7 @@ public function testBuildXRechnungExtendedExample(): void
$headerTax2->rateApplicablePercent = '19.00';

$invoice->supplyChainTradeTransaction->applicableHeaderTradeSettlement->specifiedTradePaymentTerms[] = $paymentTerms = new TradePaymentTerms();
$paymentTerms->directDebitMandateID = 'Mandate Reference';
$paymentTerms->description = 'Zahlbar innerhalb 30 Tagen netto bis 04.04.2018, 3% Skonto innerhalb 10 Tagen bis 15.03.2018';

$invoice->supplyChainTradeTransaction->applicableHeaderTradeSettlement->specifiedTradeSettlementHeaderMonetarySummation = $summation = new TradeSettlementHeaderMonetarySummation();
Expand Down
2 changes: 2 additions & 0 deletions tests/zugferd211/Tests/zugferd_2p1_XRECHNUNG_Extended.xml
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,7 @@ Handelsregisternummer: H A 123
</ram:DeliveryNoteReferencedDocument>
</ram:ApplicableHeaderTradeDelivery>
<ram:ApplicableHeaderTradeSettlement>
<ram:CreditorReferenceID>TEST1234</ram:CreditorReferenceID>
<ram:PaymentReference>421102</ram:PaymentReference>
<ram:InvoiceCurrencyCode>EUR</ram:InvoiceCurrencyCode>
<ram:PayeeTradeParty>
Expand Down Expand Up @@ -330,6 +331,7 @@ Handelsregisternummer: H A 123
</ram:SpecifiedLogisticsServiceCharge>
<ram:SpecifiedTradePaymentTerms>
<ram:Description>Zahlbar innerhalb 30 Tagen netto bis 04.04.2018, 3% Skonto innerhalb 10 Tagen bis 15.03.2018</ram:Description>
<ram:DirectDebitMandateID>Mandate Reference</ram:DirectDebitMandateID>
</ram:SpecifiedTradePaymentTerms>
<ram:SpecifiedTradeSettlementHeaderMonetarySummation>
<ram:LineTotalAmount>465.00</ram:LineTotalAmount>
Expand Down

0 comments on commit 126f449

Please sign in to comment.