test/Parser/Banking/Mt940/DebitCreditTest.php 1 location
|
@@ 16-27 (lines=12) @@
|
13 |
|
* @param string $dOrC D|C |
14 |
|
* @param string $statement |
15 |
|
*/ |
16 |
|
public function testDebitCredit($dOrC, $statement) |
17 |
|
{ |
18 |
|
$engine = new Unknown(); |
19 |
|
$property = new \ReflectionProperty($engine, 'currentTransactionData'); |
20 |
|
$property->setAccessible(true); |
21 |
|
|
22 |
|
$method = new \ReflectionMethod($engine, 'parseTransactionDebitCredit'); |
23 |
|
$method->setAccessible(true); |
24 |
|
|
25 |
|
$property->setValue($engine, $statement); |
26 |
|
$this->assertEquals($dOrC, $method->invoke($engine)); |
27 |
|
} |
28 |
|
|
29 |
|
/** |
30 |
|
* @return array |
test/Parser/Banking/Mt940/Engine/ParseDescriptionTest.php 1 location
|
@@ 16-26 (lines=11) @@
|
13 |
|
* @param $input |
14 |
|
* @param $expected |
15 |
|
*/ |
16 |
|
public function testDebitCredit($input, $expected) |
17 |
|
{ |
18 |
|
$engine = new Unknown(); |
19 |
|
$property = new \ReflectionProperty($engine, 'currentTransactionData'); |
20 |
|
$property->setAccessible(true); |
21 |
|
$property->setValue($engine, $input); |
22 |
|
|
23 |
|
$method = new \ReflectionMethod($engine, 'parseTransactionDescription'); |
24 |
|
$method->setAccessible(true); |
25 |
|
$this->assertEquals($expected, $method->invoke($engine)); |
26 |
|
} |
27 |
|
|
28 |
|
/** |
29 |
|
* @return array |
test/Parser/Banking/Mt940/Engine/ParseTransactionDebitCreditTest.php 1 location
|
@@ 14-23 (lines=10) @@
|
11 |
|
/** |
12 |
|
* @dataProvider getTransactions |
13 |
|
*/ |
14 |
|
public function test($inputString, $expected) { |
15 |
|
$engine = new Unknown(); |
16 |
|
$property = new \ReflectionProperty($engine, 'currentTransactionData'); |
17 |
|
$property->setAccessible(true); |
18 |
|
$property->setValue($engine, $inputString); |
19 |
|
|
20 |
|
$method = new \ReflectionMethod($engine, 'parseTransactionDebitCredit'); |
21 |
|
$method->setAccessible(true); |
22 |
|
$this->assertSame($expected, $method->invoke($engine)); |
23 |
|
} |
24 |
|
|
25 |
|
public function getTransactions() |
26 |
|
{ |
test/Parser/Banking/Mt940/Engine/ParseTransactionPriceTest.php 1 location
|
@@ 14-23 (lines=10) @@
|
11 |
|
/** |
12 |
|
* @dataProvider getTransactions |
13 |
|
*/ |
14 |
|
public function test($inputString, $expected) { |
15 |
|
$engine = new Unknown(); |
16 |
|
$property = new \ReflectionProperty($engine, 'currentTransactionData'); |
17 |
|
$property->setAccessible(true); |
18 |
|
$property->setValue($engine, $inputString); |
19 |
|
|
20 |
|
$method = new \ReflectionMethod($engine, 'parseTransactionPrice'); |
21 |
|
$method->setAccessible(true); |
22 |
|
$this->assertSame($expected, $method->invoke($engine)); |
23 |
|
} |
24 |
|
|
25 |
|
public function getTransactions() |
26 |
|
{ |
test/Parser/Banking/Mt940/Engine/Spk/ParseTransactionPriceTest.php 1 location
|
@@ 14-23 (lines=10) @@
|
11 |
|
/** |
12 |
|
* @dataProvider getTransactions |
13 |
|
*/ |
14 |
|
public function test($inputString, $expected) { |
15 |
|
$engine = new Spk; |
16 |
|
$property = new \ReflectionProperty($engine, 'currentTransactionData'); |
17 |
|
$property->setAccessible(true); |
18 |
|
$property->setValue($engine, $inputString); |
19 |
|
|
20 |
|
$method = new \ReflectionMethod($engine, 'parseTransactionPrice'); |
21 |
|
$method->setAccessible(true); |
22 |
|
$this->assertSame($expected, $method->invoke($engine)); |
23 |
|
} |
24 |
|
|
25 |
|
public function getTransactions() |
26 |
|
{ |