Example #1
0
 public function test_createFull()
 {
     $c = Unify::createFull();
     $this->assertEquals(true, $c instanceof Collection);
     $this->assertEquals(true, $c->extensions()->exists('avg'));
     $this->assertEquals(true, $c->extensions()->exists('renameAll'));
     $this->assertEquals(true, $c->extensions()->exists('toHTML'));
 }
Example #2
0
 /**
  * @depends test_Max
  *
  * @expectedException LogicException
  * @expectedExceptionCode 340
  */
 public function test_Max_Exception()
 {
     Unify::createFull()->append(array(['name' => 'item1', 'value' => 'test1']))->max('value');
 }
Example #3
0
 /**
  * @depends test_addXML_toXml_isXMLValid
  *
  * @expectedException InvalidArgumentException
  * @expectedExceptionCode 420
  */
 public function test_toXML_Exception()
 {
     Unify::createFull()->toXML('item', []);
 }
Example #4
0
 /**
  * @depends test_toJson
  *
  * @expectedException InvalidArgumentException
  * @expectedExceptionCode 520
  */
 public function test_toJson_Exception()
 {
     Unify::createFull()->toJson([]);
 }
Example #5
0
 /**
  * @depends test_Limit_Exception
  *
  * @expectedException InvalidArgumentException
  * @expectedExceptionCode 251
  */
 public function test_Limit_Exception2()
 {
     Unify::createFull()->limit(5, '');
 }