Permalink
Browse files

added time test

  • Loading branch information...
1 parent 7766510 commit 54b25df734e38d3780d5262e4e96e6d76c4bb274 @nicholas-eden committed Sep 6, 2013
Showing with 4 additions and 1 deletion.
  1. +4 −1 tests/TestingAidsTest.php
@@ -61,9 +61,11 @@ public function testParseWithTestValueSet()
public function testParseRelativeWithTestValueSet()
{
- $notNow = Carbon::parse('2013-09-01');
+ $notNow = Carbon::parse('2013-09-01 05:30:15');
Carbon::setTestNow($notNow);
+ $this->assertEquals('05:30:15', Carbon::parse('tomorrow')->toTimeString());
+
$this->assertEquals('2013-09-02', Carbon::parse('tomorrow')->toDateString());
$this->assertEquals('2013-08-31', Carbon::parse('yesterday')->toDateString());
@@ -84,5 +86,6 @@ public function testParseRelativeWithTestValueSet()
$this->assertEquals('2013-08-25', Carbon::parse('last sunday')->toDateString());
+
}
}

0 comments on commit 54b25df

Please sign in to comment.