mirror of
https://github.com/e107inc/e107.git
synced 2025-08-02 20:57:26 +02:00
Comment added for date lapse issue.
This commit is contained in:
@@ -167,6 +167,13 @@
|
|||||||
$actual = $this->dateObj->computeLapse($older, $newer, false, true, 'long');
|
$actual = $this->dateObj->computeLapse($older, $newer, false, true, 'long');
|
||||||
$expected = '1 day, 22 hours, 49 minutes, 55 seconds ago';
|
$expected = '1 day, 22 hours, 49 minutes, 55 seconds ago';
|
||||||
$this->assertEquals($expected, $actual);
|
$this->assertEquals($expected, $actual);
|
||||||
|
|
||||||
|
|
||||||
|
//FIXME fails with future dates. Expected: "In 2 weeks" or "2 weeks from now"
|
||||||
|
$newer = strtotime("+2 weeks");
|
||||||
|
$actual = $this->dateObj->computeLapse($newer, time(), false, true, 'short');
|
||||||
|
|
||||||
|
// var_dump($actual);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -232,4 +239,11 @@
|
|||||||
|
|
||||||
// $this->fail(print_r($result,true));
|
// $this->fail(print_r($result,true));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user