forked from ch2877/swiss-payment
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
PstlAdr field is optional is the Dbtr section for BankCreditTransfer …
…transactions. I add a new 'EmptyPostalAddress' implementation which doesn't generate any DOMElement I test the constructor of BankCreditTransfer with an instance of this implementation I add a transaction of 1300 CHF in the CustomerCreditTransferTest, and check that the generated xml file is ever valid (the headers CtrlSum and NbOfTxs change in consequence)
- Loading branch information
1 parent
862fafa
commit ecf2ae5
Showing
4 changed files
with
74 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<?php | ||
/** | ||
* Created by PhpStorm. | ||
* User: celinederoland | ||
* Date: 23.05.18 | ||
* Time: 11:40 | ||
*/ | ||
|
||
namespace Z38\SwissPayment; | ||
|
||
class EmptyPostalAddress implements PostalAddressInterface { | ||
|
||
/** | ||
* Returns a XML representation of the address | ||
* | ||
* @param \DOMDocument $doc | ||
* | ||
* @return \DOMElement The built DOM element | ||
*/ | ||
public function asDom(\DOMDocument $doc) { | ||
|
||
return null; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters