Skip to content

Commit

Permalink
Fix tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
dereuromark committed Dec 31, 2024
1 parent 72be53d commit 77a6add
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions tests/TestCase/I18n/DateTimeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -455,11 +455,10 @@ public function testAgeByYear() {

// year only
$is = $this->Time->ageByYear(2000);
//$this->out($is);
$this->assertEquals((date('Y') - 2001) . '/' . (date('Y') - 2000), $is);
$this->assertTrue($is === (date('Y') - 2001) . '/' . (date('Y') - 2000) || $is === (string)((date('Y') - 2000)));

$is = $this->Time->ageByYear(1985);
$this->assertEquals((date('Y') - 1986) . '/' . (date('Y') - 1985), $is);
$this->assertTrue($is === (date('Y') - 1986) . '/' . (date('Y') - 1985) || $is === (string)((date('Y') - 1985)));

// with month
$month = date('n') + 1;
Expand Down

0 comments on commit 77a6add

Please sign in to comment.