diff --git a/src/DataSet/DataSet.php b/src/DataSet/DataSet.php index 7944dfd..709ce0c 100644 --- a/src/DataSet/DataSet.php +++ b/src/DataSet/DataSet.php @@ -66,9 +66,7 @@ public function dropAllCollections() { */ public function buildCollections() { foreach ($this->fixture as $collection => $data) { - foreach ($data as $entry) { - $this->connection->collection($collection)->insertOne($entry); - } + $this->connection->collection($collection)->insertMany($data); } return $this; }