PHPackages                             phalcana/unittest - 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. phalcana/unittest

ActivePhalcana-module

phalcana/unittest
=================

Unit testing module for Phalcana using PHPUnit

v0.8.3(10y ago)0642BSD-3-ClausePHP

Since Sep 10Pushed 10y ago1 watchersCompare

[ Source](https://github.com/braf/phalcana-unittest)[ Packagist](https://packagist.org/packages/phalcana/unittest)[ Docs](http://phalcana.com)[ RSS](/packages/phalcana-unittest/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (4)Dependencies (2)Versions (5)Used By (2)

Phalcana Unit Testing Module
============================

[](#phalcana-unit-testing-module)

This is a Unit testing module for Phalcana. This does not actually contain any of the tests, the tests are defined in the tests folder for each module and in the core.

Installation
------------

[](#installation)

This module is installed by default with the Phalcana project by composer for more information see the [Phalcana Project](http://github.com/braf/phalcana-unittest)

Running Tests
-------------

[](#running-tests)

The unit tests can be run by using the one of following commands from the project root directory.

Using the binary that comes from installing via composer.

```
vendor/phpunit/phpunit/phpunit --bootstrap modules/unittest/index.php modules/unittest/tests.php
```

With php unit installed globally on your system.

```
phpunit --bootstrap modules/unittest/index.php modules/unittest/tests.php
```

Writing tests
-------------

[](#writing-tests)

Tests are stored in the appropriate module in a folder called `tests` and should extend be the in the namespace `Phalcana\Tests` and should extend the class `Phalcana\Unittests\TestCase`.

Please find below an example unit test header.

```
