/** * test working time */ public function testWorkingTimeTemplate() { $recordData = array('title' => 'lazy worker', 'type' => 'static', 'json' => '{"days":[1,1,1,1,1,0,0]}', 'working_hours' => 5); $savedWT = $this->_json->saveWorkingTime($recordData); $this->assertEquals($savedWT['title'], 'lazy worker'); // test duplicate exception $this->setExpectedException('Tinebase_Exception_Duplicate'); $this->_json->saveWorkingTime($recordData); }