Skip to content

Commit

Permalink
switch to previous ruleset
Browse files Browse the repository at this point in the history
  • Loading branch information
Fabian Derschatta committed Nov 9, 2016
1 parent 4fae199 commit 00b3708
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
2 changes: 1 addition & 1 deletion library/IBAN/Generation/IBANGeneratorDE.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
class IBANGeneratorDE extends IBANGenerator
{

const CURRENT_RULES = '20161205';
const CURRENT_RULES = 20140303;

public function __construct()
{
Expand Down
18 changes: 13 additions & 5 deletions tests/library/IBAN/Generation/IBANGeneratorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -312,9 +312,11 @@ public function testGenerateIbanForRuleDE002400()

public function testGenerateIbanForRuleDE002500()
{
// No bank included in newest rules
// $this->assertIban('DE81600501010002777939', IBANGenerator::DE('64150182', '2777939'));
// $this->assertIban('DE80600501017893500686', IBANGenerator::DE('64450288', '7893500686'));
if (IBANGeneratorDE::CURRENT_RULES >= 20161205) {
$this->markTestSkipped('No bank included in newest rules');
}
$this->assertIban('DE81600501010002777939', IBANGenerator::DE('64150182', '2777939'));
$this->assertIban('DE80600501017893500686', IBANGenerator::DE('64450288', '7893500686'));
}

public function testGenerateIbanForRuleDE002600()
Expand Down Expand Up @@ -437,6 +439,10 @@ public function testGenerateIbanForRuleDE004200()

public function testGenerateIbanForRuleDE004201()
{

if (IBANGeneratorDE::CURRENT_RULES < 20161205) {
$this->markTestSkipped('Rule is not active yet');
}
$this->assertIban('', IBANGenerator::DE('10000000', '12345'));
$this->assertIban('', IBANGenerator::DE('10000000', '12300123'));
$this->assertIban('', IBANGenerator::DE('10000000', '1231200000'));
Expand Down Expand Up @@ -502,8 +508,10 @@ public function testGenerateIbanForRuleDE005100()

public function testGenerateIbanForRuleDE005200()
{
// no rule for this bank included in newest rules
//$this->assertIban('DE38600501010002662604', IBANGenerator::DE('67220020', '5308810004'));
if (IBANGeneratorDE::CURRENT_RULES >= 20161205) {
$this->markTestSkipped('No bank included in newest rules');
}
$this->assertIban('DE38600501010002662604', IBANGenerator::DE('67220020', '5308810004'));
}

public function testGenerateIbanForRuleDE005300()
Expand Down

0 comments on commit 00b3708

Please sign in to comment.