quarkdev/tendo
Composer 安装命令:
composer require --dev quarkdev/tendo
包简介
README 文档
README
Tendo is a really simple testing framework inspired by Ava.
How to run
composer require 'quarkdev/tendo'
Example
<?php use Tendo\Tendo; require 'vendor/autoload.php'; $test = new Tendo(); $test('title', function($t) { $t->pass(); // yes }); $test('title 2', function($t) { $t->is(123, '123'); // nop }); $test('Plan', function($t) { $t->plan(2); for ($i = 0; $i < 3; $i++) { $t->true($i < 3); } }); // fails, 3 assertions are executed which is too many $test->results();
Command line example
The $test variable is auto injected, you dont have to instantiate Tendo.
Example with myTest.php:
<?php $test('title', function($t) { $t->pass(); // yes }); $test('title 2', function($t) { $t->is(123, '123'); // nop });
You can now run the test via the command line :
./vendor/bin/tendo myTest.php
Note: You can run multiple tests via the commande line ./vendor/bin/tendo test1.php test2.php ....
统计信息
- 总下载量: 99
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-04-03