PHPackages                             davjand/codecept-symphonycms-db - 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. [Testing &amp; Quality](/categories/testing)
4. /
5. davjand/codecept-symphonycms-db

ActiveLibrary[Testing &amp; Quality](/categories/testing)

davjand/codecept-symphonycms-db
===============================

Codeception SymphonyCMS Database Module

0.2(10y ago)021PHP

Since Oct 29Pushed 10y ago1 watchersCompare

[ Source](https://github.com/davjand/codecept-symphonycms-db)[ Packagist](https://packagist.org/packages/davjand/codecept-symphonycms-db)[ RSS](/packages/davjand-codecept-symphonycms-db/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (2)Versions (3)Used By (0)

Readme
======

[](#readme)

- Use this at your own risk.
- MIT License
-

A codeception module to facilitate integration with Symphony CMS ().

This is intended to be used in conjunction with the existing Db module for setup/teardown of databases. It currently offers functions putting your own fixture data into the database

**2015-10-30 - Version: 0.2**

- Renamed haveInDatabseFunctions
- Added YML loading functionality

**2015-10-29 - Version: 0.1**

- Initial Release

Setup
-----

[](#setup)

The module has no configuration parameters however you must define the symphony DOCROOT within your *bootstrap.php* file for this to work

An older version of symphony is included in the repository (the repo was developed for testing an old repo) however by changing the path below to **your included symphony source** that you are testing you can use that.

```
define('DOCROOT',__DIR__ . '/../symphony/2.3.6/');
```

This will access the database through the settings in your **manifest/config.php** file.

Please note that in some environments, you need to have your host as **127.0.0.1** for the database rather than localhost for using with codeception.

Config
------

[](#config)

Enable in your configuration file as below. You can define a custom path to your fixtures folder for included yml fixtures

```
modules:
    config:
        SymphonyCMSDb:
            fixtures: 'tests/_fixtures'
```

Functions
---------

[](#functions)

symHaveFixtureInDatabase($fixture)
----------------------------------

[](#symhavefixtureindatabasefixture)

Load a yml file of data from your fixtures folder (see config above).

Format is

```
secton-handle:
    -
        field-name-one: 'value'
        field-name-two: 'value2'
```

Subsequent entries can be associated with previous entries using the format *%section:position%* as seen in the example below. The position starts at 1, not 0. The section with the relation must **be defined after** the entry it is being related to or an error will be thrown.

NB: It is not currently possible to associate entries in the same section together.

For Example.

```
people:
    -
        first-name: 'James'
        last-name: 'Bond'
    -
        first-name: 'Daniel'
        last-name: 'Craig'
dogs:
    -
        name: 'Rover'
        owner: '%people:2%'
```

### symHaveInDatabase($data)

[](#symhaveindatabasedata)

Inserts multiple sections data into the database in one go.

Subsequent sections can be related to each other using the *%section:position%* format as above

```
array(
    'section-name' => array(
        array(
            'field-name': value
            'field-name': value
            ),
    )
);
```

### symHaveEntriesInDatabase($sectionHandle,$data)

[](#symhaveentriesindatabasesectionhandledata)

$data should be a multi-dimensional array in the format

```
array(
    array(
        'field-name': value
        'field_name': value
        ),
    etc
    );
```

It *returns* an array of the inserted IDs

### symHaveEntryInDatabase($sectionHandle,$data)

[](#symhaveentryindatabasesectionhandledata)

Similar to symHaveInDatabase except exceptions only one entry. Accepts the data in key value format.

### symUpdateDatabaseRecord($sectionHandle,$entryId,$data)

[](#symupdatedatabaserecordsectionhandleentryiddata)

This will update an existing record with the data passed. Accepts the data in key value format.

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity54

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.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

3901d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/38486826fb52088363649ef1e3059eb57f504e30b777b70281a845117fc34335?d=identicon)[davjand](/maintainers/davjand)

---

Top Contributors

[![davjand](https://avatars.githubusercontent.com/u/372174?v=4)](https://github.com/davjand "davjand (9 commits)")

###  Code Quality

TestsCodeception

### Embed Badge

![Health badge](/badges/davjand-codecept-symphonycms-db/health.svg)

```
[![Health](https://phpackages.com/badges/davjand-codecept-symphonycms-db/health.svg)](https://phpackages.com/packages/davjand-codecept-symphonycms-db)
```

###  Alternatives

[behat/behat

Scenario-oriented BDD framework for PHP

4.0k101.8M2.2k](/packages/behat-behat)[phpro/grumphp

A composer plugin that enables source code quality checks.

4.3k16.7M1.0k](/packages/phpro-grumphp)[orchestra/testbench

Laravel Testing Helper for Packages Development

2.2k42.5M40.9k](/packages/orchestra-testbench)[craftcms/cms

Craft CMS

3.6k3.6M3.1k](/packages/craftcms-cms)[tempest/framework

The PHP framework that gets out of your way.

2.2k34.4k15](/packages/tempest-framework)[rcsofttech/audit-trail-bundle

Enterprise-grade, high-performance Symfony audit trail bundle. Automatically track Doctrine entity changes with split-phase architecture, multiple transports (HTTP, Queue, Doctrine), and sensitive data masking.

1189.8k](/packages/rcsofttech-audit-trail-bundle)

PHPackages © 2026

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