Commit 794ff670 authored by Fabrice Gangler's avatar Fabrice Gangler 🎨
Browse files

TEST: add data fixtures dependency (doctrine-fixtures)

Documentation:
https://symfony.com/doc/master/bundles/DoctrineFixturesBundle/

Installation:
composer require --dev orm-fixtures

Refs: #12
parent 23e0bc20
......@@ -37,6 +37,7 @@
"symfony/yaml": "5.0.*"
},
"require-dev": {
"doctrine/doctrine-fixtures-bundle": "^3.3",
"fzaninotto/faker": "^1.9",
"jakub-onderka/php-parallel-lint": "^1.0",
"phpro/grumphp": "^0.18.0",
......
......@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
"content-hash": "1ae24e97e0d4714a9d66c6f10eac53c6",
"content-hash": "9afec40bca4e1d3d28072af3653c2eb1",
"packages": [
{
"name": "doctrine/annotations",
......@@ -6113,6 +6113,137 @@
}
],
"packages-dev": [
{
"name": "doctrine/data-fixtures",
"version": "1.4.2",
"source": {
"type": "git",
"url": "https://github.com/doctrine/data-fixtures.git",
"reference": "39e9777c9089351a468f780b01cffa3cb0a42907"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/doctrine/data-fixtures/zipball/39e9777c9089351a468f780b01cffa3cb0a42907",
"reference": "39e9777c9089351a468f780b01cffa3cb0a42907",
"shasum": ""
},
"require": {
"doctrine/common": "^2.11",
"doctrine/persistence": "^1.3.3",
"php": "^7.2"
},
"conflict": {
"doctrine/phpcr-odm": "<1.3.0"
},
"require-dev": {
"alcaeus/mongo-php-adapter": "^1.1",
"doctrine/coding-standard": "^6.0",
"doctrine/dbal": "^2.5.4",
"doctrine/mongodb-odm": "^1.3.0",
"doctrine/orm": "^2.7.0",
"phpunit/phpunit": "^7.0"
},
"suggest": {
"alcaeus/mongo-php-adapter": "For using MongoDB ODM with PHP 7",
"doctrine/mongodb-odm": "For loading MongoDB ODM fixtures",
"doctrine/orm": "For loading ORM fixtures",
"doctrine/phpcr-odm": "For loading PHPCR ODM fixtures"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.4.x-dev"
}
},
"autoload": {
"psr-4": {
"Doctrine\\Common\\DataFixtures\\": "lib/Doctrine/Common/DataFixtures"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Jonathan Wage",
"email": "jonwage@gmail.com"
}
],
"description": "Data Fixtures for all Doctrine Object Managers",
"homepage": "http://www.doctrine-project.org",
"keywords": [
"database"
],
"time": "2020-01-17T11:11:28+00:00"
},
{
"name": "doctrine/doctrine-fixtures-bundle",
"version": "3.3.0",
"source": {
"type": "git",
"url": "https://github.com/doctrine/DoctrineFixturesBundle.git",
"reference": "8f07fcfdac7f3591f3c4bf13a50cbae05f65ed70"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/doctrine/DoctrineFixturesBundle/zipball/8f07fcfdac7f3591f3c4bf13a50cbae05f65ed70",
"reference": "8f07fcfdac7f3591f3c4bf13a50cbae05f65ed70",
"shasum": ""
},
"require": {
"doctrine/data-fixtures": "^1.3",
"doctrine/doctrine-bundle": "^1.11|^2.0",
"doctrine/orm": "^2.6.0",
"php": "^7.1",
"symfony/config": "^3.4|^4.3|^5.0",
"symfony/console": "^3.4|^4.3|^5.0",
"symfony/dependency-injection": "^3.4|^4.3|^5.0",
"symfony/doctrine-bridge": "^3.4|^4.1|^5.0",
"symfony/http-kernel": "^3.4|^4.3|^5.0"
},
"require-dev": {
"doctrine/coding-standard": "^6.0",
"phpunit/phpunit": "^7.4",
"symfony/phpunit-bridge": "^4.1|^5.0"
},
"type": "symfony-bundle",
"extra": {
"branch-alias": {
"dev-master": "3.3.x-dev"
}
},
"autoload": {
"psr-4": {
"Doctrine\\Bundle\\FixturesBundle\\": ""
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
},
{
"name": "Doctrine Project",
"homepage": "http://www.doctrine-project.org"
},
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
}
],
"description": "Symfony DoctrineFixturesBundle",
"homepage": "http://www.doctrine-project.org",
"keywords": [
"Fixture",
"persistence"
],
"time": "2019-11-13T15:46:58+00:00"
},
{
"name": "easycorp/easy-log-handler",
"version": "v1.0.9",
......
......@@ -12,4 +12,5 @@
Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle::class => ['all' => true],
Symfony\Bundle\SecurityBundle\SecurityBundle::class => ['all' => true],
Symfony\Bundle\MakerBundle\MakerBundle::class => ['dev' => true],
Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle::class => ['dev' => true, 'test' => true],
];
<?php
namespace App\DataFixtures;
use Doctrine\Bundle\FixturesBundle\Fixture;
use Doctrine\Common\Persistence\ObjectManager;
class AppFixtures extends Fixture
{
public function load(ObjectManager $manager)
{
// $product = new Product();
// $manager->persist($product);
$manager->flush();
}
}
......@@ -20,6 +20,9 @@
"doctrine/common": {
"version": "2.12.0"
},
"doctrine/data-fixtures": {
"version": "1.4.2"
},
"doctrine/dbal": {
"version": "v2.10.1"
},
......@@ -38,6 +41,18 @@
"src/Repository/.gitignore"
]
},
"doctrine/doctrine-fixtures-bundle": {
"version": "3.0",
"recipe": {
"repo": "github.com/symfony/recipes",
"branch": "master",
"version": "3.0",
"ref": "fc52d86631a6dfd9fdf3381d0b7e3df2069e51b3"
},
"files": [
"src/DataFixtures/AppFixtures.php"
]
},
"doctrine/doctrine-migrations-bundle": {
"version": "1.2",
"recipe": {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment