Exemplo n.º 1
0
 public function testCanNotInsertBeforeWhenReadOnly()
 {
     $list = new TList(array(5), true);
     try {
         $list->insertBefore(5, 6);
         self::fail('An expected TInvalidOperationException was not raised');
     } catch (TInvalidOperationException $e) {
     }
     try {
         $list->insertBefore(8, 6);
         self::fail('An expected TInvalidOperationException was not raised');
     } catch (TInvalidOperationException $e) {
     }
 }