コード例 #1
0
ファイル: ArrayUtilTest.php プロジェクト: mystlabs/mistyutils
 public function testRemoveBlankElements()
 {
     $input = array(1, 2, null, 'test', '', 2);
     $output = ArrayUtil::removeBlankElements($input);
     $this->assertEquals(4, count($output));
     $this->assertEquals(1, $output[0]);
     $this->assertEquals(2, $output[1]);
     $this->assertEquals('test', $output[3]);
     $this->assertEquals(2, $output[5]);
 }