Пример #1
0
 public function testTablemanOrderColumns()
 {
     $columnBag = with(new \mechanicious\Columnizer\Columnizer($this->mockData))->columnizeRowArray();
     $tableman = new \mechanicious\Tableman\Tableman($columnBag);
     $tableman->orderColumns(array('hobby', 'age', 'id', 'name'));
     $this->assertEquals($this->cleanWhiteSpace($tableman->getJSON()), $this->cleanWhiteSpace('
   {
     "hobby":[null,"sport"],
     "age":[25, 27],
     "id":[1,2],
     "name":["Joe","Tony"]
   }'));
 }