/** * @covers ::addArray */ public function testAddArray() { $models = new Models(); $array = [new Model(), new Model()]; $models->addArray($array); $this->assertSame($array, Objects::toArray($models->all())); }
/** * @param AbstractModel[] $models * @return LinkMany $this */ public function addArray(array $models) { $this->current->addArray($models); return $this; }