This tag is for questions about atoum, a programmer-oriented testing framework for PHP. It is a modern unit testing framework designed to be more simple and intuitive than xUnit frameworks.
#Summary According to the atoum documentation
atoum is a simple, modern and intuitive unit testing framework for PHP! It is completely standalone, everything is available and works out of the box.
#Quick info & Links
Homepage: https://atoum.org/
Documentation: https://docs.atoum.org/
GitHub: https://github.com/atoum/atoum/
#Installing atoum
##Installation via PHAR
$ wget http://downloads.atoum.org/nightly/atoum.phar
$ php atoum.phar
##Installation via Composer
For a global install, execute:
$ composer global require "atoum/atoum=^3.2"
To install atoum for your project, add the following lines in your project's composer.json
file:
{
"require-dev": {
"atoum/atoum": "^3.2"
}
}
Or use the composer
command :
$ composer require --dev atoum/atoum
#Basic test sample
<?php
$this
->given($computer = new computer())
->if($computer->prepare())
->and(
$computer->setFirstOperand(2),
$computer->setSecondOperand(2)
)
->then
->object($computer->add())
->isIdenticalTo($computer)
->integer($computer->getResult())
->isEqualTo(4)
;