diff options
Diffstat (limited to 'tests/units/ProjectTest.php')
-rw-r--r-- | tests/units/ProjectTest.php | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/units/ProjectTest.php b/tests/units/ProjectTest.php index 45bc63fc..b7f168d7 100644 --- a/tests/units/ProjectTest.php +++ b/tests/units/ProjectTest.php @@ -44,6 +44,18 @@ class ProjectTest extends Base $this->assertEmpty($project['token']); } + public function testCreationWithStartAndDate() + { + $p = new Project($this->container); + + $this->assertEquals(1, $p->create(array('name' => 'UnitTest', 'start_date' => '2015-01-01', 'end_date' => '2015-12-31'))); + + $project = $p->getById(1); + $this->assertNotEmpty($project); + $this->assertEquals('2015-01-01', $project['start_date']); + $this->assertEquals('2015-12-31', $project['end_date']); + } + public function testCreationWithDefaultCategories() { $p = new Project($this->container); |