/** * Test deleting a tasklog * */ public function testDelete() { $this->obj->bind($this->post_data); $result = $this->obj->store(); $this->assertTrue($result); $original_id = $this->obj->task_log_id; $result = $this->obj->delete(); $item = new CTask_Log(); $item->overrideDatabase($this->mockDB); $this->mockDB->stageHash(array('task_log_name' => '', 'task_log_description' => '')); $item->load($original_id); $this->assertTrue(is_a($item, 'CTask_Log')); $this->assertEquals('', $item->task_log_name); $this->assertEquals('', $item->task_log_description); //TODO: figure out a way to test the CTask cascading totals //TODO: figure out a way to test the CProject cascading totals }