Download the PHP package linkorb/transmogrifier without Composer

On this page you can find all versions of the php package linkorb/transmogrifier. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package transmogrifier

Transmogrifier

Transmogrifier is a tool to help setup your database fixtures before running your tests.

You can use it in the following ways:

  1. As a simple command-line utility (great for your build scripts and continuous integration)
  2. As a PHP library
  3. As a Behat extension, enabling Gherkin statements for automated BDD database testing

1. Command-line utility

You can use Transmogrifier as a command-line utility (stand-alone, or as part of your PHP project through composer).

Standalone

  1. clone this git repository
  2. run composer install to install all dependencies
  3. run bin/transmogrifier --help for a list of available commands

Through composer, in your PHP project:

Open your composer.json file, and add this to the require section:

You can now run vendor/bin/transmogrifier.

Adding transmogrifier commands to an existing Symfony/Console application

Add the following line to an existing Symfony/Console application in order to enable the Transmogrifier commands to it:

Available commands

transmogrifier:datasetapply

The most interesting usage through the command-line is the transmogrifier:applydataset command.

You can use it like this:

This command will ensure that the dbname database contains the dataset specified in example/user.yml

2. PHP Library

You can use the Transmogrifier very easily from within your own PHP projects as a library.

Installing the library through composer

pen your composer.json file, and add this to the require section:

How to use the library

The 2 main classes are:

Here's an example usage:

3. Behat Extension

There is a Transmogrifier Extension available for Behat!

This allows you to use Transmogrifier directly from your Behat .feature files.

Check out the extension and it's documentation here:

Supported file-formats

The dataset importer is based on phpunit/dbunit. It currently supports the following file-formats:

The Dataset loader guesses the format based on the file-extension.

Please refer to the example/ directory for datasets in these formats. The PHPUnit documentation contains further information about the loaders:

Database .conf files

To simplify connecting to your database, Transmogrify can load conneciton settings from a simple .conf file.

An example file looks like this:

You can use these .conf files in all Transmogrifier modes: Command-line, Behat, or library. The connection is established through PDO, so all PDO supported databases will work.

Example datasets

The examples/ directory contains a few datasets you can use to try out Transmogrifier, see how it works, and copy as a starting-point for your own datasets.

Create the schema

The examples will ensure 2 users, 'Calvin' and 'Hobbes', are registed in your user table.

Before you can try these out, use the following SQL to generate the user table in your test database:

Brought to you by the LinkORB Engineering team


Check out our other projects at linkorb.com/engineering.

Btw, we're hiring!


All versions of transmogrifier with dependencies

PHP Build Version
Package Version
Requires symfony/console Version ~2.4
phpunit/phpunit Version ~3.7
phpunit/dbunit Version ~1.3
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package linkorb/transmogrifier contains the following files

Loading the files please wait ....