PHPackages                             ewgo/doctrine-fixtures-module - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. ewgo/doctrine-fixtures-module

ActiveZf2-module[Database &amp; ORM](/categories/database)

ewgo/doctrine-fixtures-module
=============================

Zend Framework 2 integration with the Doctrine Fixtures library

64.8k3

Since Jul 26Pushed 12y ago3 watchersCompare

[ Source](https://github.com/Ewgo/DoctrineFixturesModule)[ Packagist](https://packagist.org/packages/ewgo/doctrine-fixtures-module)[ RSS](/packages/ewgo-doctrine-fixtures-module/feed)WikiDiscussions master Synced 4w ago

READMEChangelogDependenciesVersions (1)Used By (0)

EwgoDoctrineFixtures module
===========================

[](#ewgodoctrinefixtures-module)

About
-----

[](#about)

The EwgoDoctrineFixtures module provides ZF2 integration with the [Doctrine Fixtures](https://github.com/doctrine/data-fixtures) library.

Installation
------------

[](#installation)

```
$ php composer.phar require ewgo/doctrine-fixtures-module
```

Add "EwgoDoctrineFixtures" to the list of loaded modules.

Configuration
-------------

[](#configuration)

Add the paths to the fixtures in your modules configuration

```
array(
    'doctrinefixtures' => array(
        'paths' => array(
            'MyModule' => __DIR__ . '/../src/MyModule/DataFixtures/ORM'
        )
    )
)
```

Usage
-----

[](#usage)

Create your fixture classes.
You can implement **Zend\\ServiceManager\\ServiceLocatorAwareInterface** in order to use the ServiceManager in your fixture class.
You can also directly extend **EwgoDoctrineFixtures\\Fixture\\ServiceLocatorAwareAbstractFixture** in order to get the benefits of both ServiceLocatorAwareInterface and AbstractFixture.

```
namespace MyModule\DataFixtures\ORM;

use EwgoDoctrineFixtures\Fixture\ServiceLocatorAwareAbstractFixture;
use Doctrine\Common\Persistence\ObjectManager;
use MyModule\Entity\User;

class LoadUserData extends ServiceLocatorAwareAbstractFixture
{
    public function load(ObjectManager $manager)
    {
        // Encode the password any way you want
        $password = $this->serviceLocator->get('MySuperEncoder')->encode('myAwesomePassword');

        $user = new User();
        $user->setUsername('test');
        $user->setPassword($password);
        $user->setPassword('test@test.com');

        $manager->persist($user);
        $manager->flush();
    }
}
```

```
$ vendor/bin/doctrine-module fixtures:load
```

See the help (--help) for options.

For more information see the [Doctrine Fixtures documentation](https://github.com/doctrine/data-fixtures).

###  Health Score

26

—

LowBetter than 41% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity24

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/160b897d0c69e4964112d3355ca4f8ff7c681140713e2649c55cff6873dc3f21?d=identicon)[jchampion](/maintainers/jchampion)

---

Top Contributors

[![jchampion](https://avatars.githubusercontent.com/u/1262628?v=4)](https://github.com/jchampion "jchampion (2 commits)")

### Embed Badge

![Health badge](/badges/ewgo-doctrine-fixtures-module/health.svg)

```
[![Health](https://phpackages.com/badges/ewgo-doctrine-fixtures-module/health.svg)](https://phpackages.com/packages/ewgo-doctrine-fixtures-module)
```

###  Alternatives

[jdorn/sql-formatter

a PHP SQL highlighting library

3.9k116.5M113](/packages/jdorn-sql-formatter)[propel/propel1

Propel is an open-source Object-Relational Mapping (ORM) for PHP5.

8441.6M87](/packages/propel-propel1)[jfelder/oracledb

Oracle DB driver for Laravel

11518.4k](/packages/jfelder-oracledb)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
