imjoehaines / flowder-json-loader
A JSON file loader for flowder
dev-master
2018-02-14 11:45 UTC
Requires
- imjoehaines/flowder: dev-master
Requires (Dev)
- phpunit/phpunit: ^5.0
This package is auto-updated.
Last update: 2024-11-29 05:03:32 UTC
README
A JSON file loader for Flowder
Usage
-
Install Flowder JSON Loader as a development dependency through Composer
$ composer install imjoehaines/flowder-json-loader --dev
-
Pass an instance of
Imjoehaines\FlowderJson\JsonLoader
to Flowder, as detailed in the Flowder readme -
Pass the path to a JSON file to
Flowder::loadFixtures
, your JSON file should contain an array of objects where each object represents a database row. For example
[ { "column_1": "value 1", "column_2": 2, "column_3": "three" }, { "column_1": "value 4", "column_2": 5, "column_3": "six" } ]