Download the PHP package axelerant/mdtt without Composer
On this page you can find all versions of the php package axelerant/mdtt. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package mdtt
Migrated Data Testing Tool (MDTT)
This tools helps you to verify the quality of your migrated data.
Installation
Usage
Basically you follow these steps:
- Specify test specifications
- Specify test definitions
- Optionally, specify transform plugins
- Run the tests
You can find the basic template for the tool usage here.
Test specification
Specify the test specification inside the directory tests/mdtt
. The specification must be written inside the spec.php
. Below is a sample specification:
Test definitions
The test definitions are written in yaml
format, and must be present inside the directory tests/mdtt
. Let's say that you want to validate the migrated user data. Create a file called validate_users.yml
. The name of the file doesn't matter.
Database
JSON
Consider that the data is exposed by the source legacy system in the following format:
Consider that the destination new system exposes data in the following format:
Transform plugin
There could be a scenario where instead of directly storing the data from source, it must be transformed in some way (say, whitespaces must be stripped) before storing it in the destination database. A QA engineer can write their own plugin, to validate the business logic that does the transformation.
The test case would look like this:
The QA engineer must specify the plugin class inside tests/mdtt/src/Plugin/Transform
. The file name (and, class name) must be same as the plugin name mentioned in the test case with the first character in upper case, i.e. Trim
. The plugin class must implement \Mdtt\Transform\Transform
interface.
Run tests
Verbose mode
You can view all available options by doing this:
Specify email where notification will be sent when test completes
Logs
By default, the log files are created inside directory called logs
. The directory will be present in the root of the test suite. The log files are named based on the datetime when the test is executed.
Features
Supported types of source
- Database (MySQL)
- JSON
Supported types of destination
- Database (MySQL)
- JSON
Supported types of channels to notify when test completes
Contribution
Fork this repository and do the changes.
Run tests
All versions of mdtt with dependencies
symfony/console Version ^6.0
symfony/yaml Version ^6.0
symfony/dependency-injection Version ^6.0
symfony/config Version ^6.0
symfony/http-kernel Version ^6.0
phpunit/phpunit Version ^9.5
symfony/dotenv Version ^6.0
sendgrid/sendgrid Version ^7.11
monolog/monolog Version ^2.4
guzzlehttp/guzzle Version ^7.4
halaxa/json-machine Version ^1.1