repo = new RDVRepo(); } public function testConstruct(){ $this->assertTrue(new RDVRepo() instanceof RDVRepo); } public function testAdd(){ $id = $this->repo->add(date('Y-m-d H:i:s',time()),30,2,1); $this->assertNotNull($id); $this->assertNotFalse($id); $this->id = $id; } public function testGetById(){ $result = $this->repo->getById($this->id); $this->assertEquals($this->id,$result['id']); } public function testDelete(){ $this->assertTrue($this->repo->delete($this->id)); } }