Beispiel #1
0
 public function testPrepend()
 {
     $array = Arr::prepend(['one', 'two', 'three', 'four'], 'zero');
     $this->assertEquals(['zero', 'one', 'two', 'three', 'four'], $array);
     $array = Arr::prepend(['one' => 1, 'two' => 2], 0, 'zero');
     $this->assertEquals(['zero' => 0, 'one' => 1, 'two' => 2], $array);
 }