PHPUnit integeration for Drupal

1.0.3 2015-08-12 14:39 UTC

This package is not auto-updated.

Last update: 2022-05-14 05:34:53 UTC


README

A group of classes used to help run tests using PHPUnit in Drupal.

upal assumes that tests are allowed to modify the database.

Usage

Configuration

Configuration can be loaded from array or file (YAML, XML, etc). Uses this config library: https://github.com/hassankhan/config.

Example:

$config = new Upal\Config();
$config->set('drush', '/path/to/drush');
$config->set('drupal_root', '/path/to/drupal/root');

$bootstrap = new Upal\Bootstrap($config);
$bootstrap->setUp();

Config Defaults

  • drush => trim(which drush)
  • root => realpath('.')
  • web_url => 'http://upal'
  • tmp => sys_get_temp_dir()
  • drupal_root => realpath('.')