/**
  * test update of snom phone
  */
 public function testCreateSnomPhoneWithLines()
 {
     $testPhone = $this->getSnomPhone();
     $sipPeer = $this->_json->saveAsteriskSipPeer($this->_getAsteriskSipPeer()->toArray());
     $this->_toDelete['sippeer'][] = $sipPeer;
     $sipPeer['context_id'] = $sipPeer['context_id']['value'];
     $sipPeer['cfi_mode'] = 'number';
     $snomLine = new Voipmanager_Model_Snom_Line(array('asteriskline_id' => $sipPeer, 'linenumber' => 1, 'lineactive' => 1, 'idletext' => 'idle'));
     $testPhone['lines'] = array($snomLine->toArray());
     // save
     $returned = $this->_json->saveSnomPhone($testPhone);
     // check result
     $this->assertGreaterThan(0, count($returned['lines']));
     $this->assertEquals($sipPeer, $returned['lines'][0]['asteriskline_id']);
 }