| @@ -11,11 +11,11 @@ | ||
| 11 | 11 | use Fhp\Model\StatementOfAccount\Statement; | 
| 12 | 12 | use Fhp\Model\StatementOfAccount\Transaction; | 
| 13 | 13 | |
| 14 | -define('FHP_BANK_URL', '');                # HBCI / FinTS Url can be found here: https://www.hbci-zka.de/institute/institut_auswahl.htm (use the PIN/TAN URL) | |
| 15 | -define('FHP_BANK_PORT', 443);              # HBCI / FinTS Port can be found here: https://www.hbci-zka.de/institute/institut_auswahl.htm | |
| 16 | -define('FHP_BANK_CODE', '');               # Your bank code / Bankleitzahl | |
| 14 | +define('FHP_BANK_URL', ''); # HBCI / FinTS Url can be found here: https://www.hbci-zka.de/institute/institut_auswahl.htm (use the PIN/TAN URL) | |
| 15 | +define('FHP_BANK_PORT', 443); # HBCI / FinTS Port can be found here: https://www.hbci-zka.de/institute/institut_auswahl.htm | |
| 16 | +define('FHP_BANK_CODE', ''); # Your bank code / Bankleitzahl | |
| 17 | 17 |  define('FHP_ONLINE_BANKING_USERNAME', ''); # Your online banking username / alias | 
| 18 | -define('FHP_ONLINE_BANKING_PIN', '');      # Your online banking PIN (NOT! the pin of your bank card!) | |
| 18 | +define('FHP_ONLINE_BANKING_PIN', ''); # Your online banking PIN (NOT! the pin of your bank card!) | |
| 19 | 19 | |
| 20 | 20 | $fints = new FinTs( | 
| 21 | 21 | FHP_BANK_URL, | 
| @@ -10,11 +10,11 @@ | ||
| 10 | 10 | use Fhp\Model\StatementOfAccount\Statement; | 
| 11 | 11 | use Fhp\Model\StatementOfAccount\Transaction; | 
| 12 | 12 | |
| 13 | -define('FHP_BANK_URL', '');                 # HBCI / FinTS Url can be found here: https://www.hbci-zka.de/institute/institut_auswahl.htm (use the PIN/TAN URL) | |
| 14 | -define('FHP_BANK_PORT', 443);               # HBCI / FinTS Port can be found here: https://www.hbci-zka.de/institute/institut_auswahl.htm | |
| 15 | -define('FHP_BANK_CODE', '');                # Your bank code / Bankleitzahl | |
| 16 | -define('FHP_ONLINE_BANKING_USERNAME', '');  # Your online banking username / alias | |
| 17 | -define('FHP_ONLINE_BANKING_PIN', '');       # Your online banking PIN (NOT! the pin of your bank card!) | |
| 13 | +define('FHP_BANK_URL', ''); # HBCI / FinTS Url can be found here: https://www.hbci-zka.de/institute/institut_auswahl.htm (use the PIN/TAN URL) | |
| 14 | +define('FHP_BANK_PORT', 443); # HBCI / FinTS Port can be found here: https://www.hbci-zka.de/institute/institut_auswahl.htm | |
| 15 | +define('FHP_BANK_CODE', ''); # Your bank code / Bankleitzahl | |
| 16 | +define('FHP_ONLINE_BANKING_USERNAME', ''); # Your online banking username / alias | |
| 17 | +define('FHP_ONLINE_BANKING_PIN', ''); # Your online banking PIN (NOT! the pin of your bank card!) | |
| 18 | 18 | |
| 19 | 19 | $fints = new FinTs( | 
| 20 | 20 | FHP_BANK_URL, | 
| @@ -10,7 +10,7 @@ | ||
| 10 | 10 | */ | 
| 11 | 11 | class SecurityIdentificationDetails extends Deg | 
| 12 | 12 |  { | 
| 13 | - const PARTY_MS = 1; // sender | |
| 13 | + const PARTY_MS = 1; // sender | |
| 14 | 14 | const CID_NONE = ''; | 
| 15 | 15 | |
| 16 | 16 | /** | 
| @@ -6,29 +6,29 @@ | ||
| 6 | 6 | |
| 7 | 7 | class MT940Test extends \PHPUnit_Framework_TestCase | 
| 8 | 8 |  { | 
| 9 | - /** | |
| 10 | - * Parser must be able to parse description lines starting with "-". | |
| 11 | - */ | |
| 12 | - public function testParseDescriptionLines() | |
| 13 | -	{ | |
| 14 | - $rawData = [ | |
| 15 | - ":20:STARTUMSE", | |
| 16 | - ":25:00000000/0221122370", | |
| 17 | - ":28C:00000/001", | |
| 18 | - ":60F:C170428EUR6670,54", | |
| 19 | - ":61:1705030503CR223,72N062NONREF", | |
| 20 | - ":86:166?00GUTSCHRIFT?109251?20EREF+CCB.122.UE.266455?21SVWZ+Re 17", | |
| 21 | - "-H-0005 vom 24.04?22.2017?30DRESDEFF850?31DE00000000000000000000?", | |
| 22 | - "32TEST TEST GBR", | |
| 23 | - ":62F:C170503EUR6894,26", | |
| 24 | - "-" | |
| 25 | - ]; | |
| 9 | + /** | |
| 10 | + * Parser must be able to parse description lines starting with "-". | |
| 11 | + */ | |
| 12 | + public function testParseDescriptionLines() | |
| 13 | +    { | |
| 14 | + $rawData = [ | |
| 15 | + ":20:STARTUMSE", | |
| 16 | + ":25:00000000/0221122370", | |
| 17 | + ":28C:00000/001", | |
| 18 | + ":60F:C170428EUR6670,54", | |
| 19 | + ":61:1705030503CR223,72N062NONREF", | |
| 20 | + ":86:166?00GUTSCHRIFT?109251?20EREF+CCB.122.UE.266455?21SVWZ+Re 17", | |
| 21 | + "-H-0005 vom 24.04?22.2017?30DRESDEFF850?31DE00000000000000000000?", | |
| 22 | + "32TEST TEST GBR", | |
| 23 | + ":62F:C170503EUR6894,26", | |
| 24 | + "-" | |
| 25 | + ]; | |
| 26 | 26 | |
| 27 | -		$parser = new MT940(implode("\r\n", $rawData)); | |
| 28 | - $result = $parser->parse(MT940::TARGET_ARRAY); | |
| 29 | - $this->assertEquals( | |
| 30 | - 'EREF+CCB.122.UE.266455SVWZ+Re 17-H-0005 vom 24.04.2017', | |
| 31 | - $result['2017-04-28']['transactions'][0]['description']['description_1'] | |
| 32 | - ); | |
| 33 | - } | |
| 27 | +        $parser = new MT940(implode("\r\n", $rawData)); | |
| 28 | + $result = $parser->parse(MT940::TARGET_ARRAY); | |
| 29 | + $this->assertEquals( | |
| 30 | + 'EREF+CCB.122.UE.266455SVWZ+Re 17-H-0005 vom 24.04.2017', | |
| 31 | + $result['2017-04-28']['transactions'][0]['description']['description_1'] | |
| 32 | + ); | |
| 33 | + } | |
| 34 | 34 | } |