PHPackages                             mandan2/prestashop-module-testing-database - 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. mandan2/prestashop-module-testing-database

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

mandan2/prestashop-module-testing-database
==========================================

This package enables more accurate automated testing for you database driven applications by using separate database.

v0.3-alpha(1y ago)03MITPHPPHP &gt;=7.1.0

Since May 28Pushed 1y ago1 watchersCompare

[ Source](https://github.com/mandan2/prestashop-module-testing-database)[ Packagist](https://packagist.org/packages/mandan2/prestashop-module-testing-database)[ RSS](/packages/mandan2-prestashop-module-testing-database/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)DependenciesVersions (4)Used By (0)

PrestaShop Module Testing Database
==================================

[](#prestashop-module-testing-database)

Overview
--------

[](#overview)

The **PrestaShop Module Testing Database** package aims to enable automated integration tests on a separate testing database. This allows data to be manipulated and truncated freely without affecting the original database, which can be preserved for manual testing. While this functionality is common in popular frameworks like Symfony or Laravel, it is now available for PrestaShop modules.

Goal
----

[](#goal)

The primary goal of this package is to:

- Enable automated integration tests on a separate testing database.
- Ensure the original database remains intact for manual testing.

How to Use
----------

[](#how-to-use)

### Installation

[](#installation)

Firstly, install this composer package in your target module:

```
composer require mandan2/prestashop-module-testing-database
```

### Creating a Clone Database

[](#creating-a-clone-database)

To create a clone database, run the following command in your terminal from module's main dir:

```
php vendor/mandan2/prestashop-module-testing-database/CreateTestDatabase.php
```

### Using the Clone Database

[](#using-the-clone-database)

To switch to the clone database, use the following command from module's main dir:

```
php vendor/mandan2/prestashop-module-testing-database/UseTestDatabase.php
```

### Using the Original Database

[](#using-the-original-database)

To revert to the original database, use the following command from module's main dir:

```
php vendor/mandan2/prestashop-module-testing-database/UseOriginalDatabase.php
```

### Integration

[](#integration)

These commands can be integrated into your workflow when launching tests. This enables seamless switching between the test and original databases, ensuring an efficient and isolated testing environment.

Requirements
------------

[](#requirements)

- Composer 2.2;
- MySQL 5.6+;
- PHP 7.1+
- PrestaShop 1.7.1+ (not tested)
- File editing permissions for app/config/parameters.php
- Folder editing permissions for the entire package

Compatibility
-------------

[](#compatibility)

Tested on: PrestaShop 8.1 within a Docker image

License
-------

[](#license)

This package is open-source and licensed under the MIT License.

Contributing
------------

[](#contributing)

Contributions are welcome! Please open an issue or submit a pull request on GitHub.

Support
-------

[](#support)

If you encounter any issues or have questions, please open an issue on the GitHub repository.

###  Health Score

17

—

LowBetter than 6% of packages

Maintenance31

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity24

Early-stage or recently created project

 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 ~1 days

Total

3

Last Release

719d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/dd7d791e381e7a0803216b7e6147b4930a2c4e3b76b814cd91beaa5758029c5f?d=identicon)[mandan2](/maintainers/mandan2)

---

Top Contributors

[![mandan2](https://avatars.githubusercontent.com/u/61560082?v=4)](https://github.com/mandan2 "mandan2 (15 commits)")

### Embed Badge

![Health badge](/badges/mandan2-prestashop-module-testing-database/health.svg)

```
[![Health](https://phpackages.com/badges/mandan2-prestashop-module-testing-database/health.svg)](https://phpackages.com/packages/mandan2-prestashop-module-testing-database)
```

###  Alternatives

[phpspec/prophecy

Highly opinionated mocking framework for PHP 5.3+

8.5k551.7M682](/packages/phpspec-prophecy)[brianium/paratest

Parallel testing for PHP

2.5k118.8M754](/packages/brianium-paratest)[beberlei/assert

Thin assertion library for input validation in business models.

2.4k96.9M570](/packages/beberlei-assert)[mikey179/vfsstream

Virtual file system to mock the real file system in unit tests.

1.4k108.0M2.7k](/packages/mikey179-vfsstream)[orchestra/testbench

Laravel Testing Helper for Packages Development

2.2k39.1M32.1k](/packages/orchestra-testbench)[phpspec/phpspec

Specification-oriented BDD framework for PHP 7.1+

1.9k36.7M3.1k](/packages/phpspec-phpspec)

PHPackages © 2026

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