philippwitzmann / testing
测试框架
1.1
2019-12-31 09:27 UTC
Requires
- fzaninotto/faker: ^1.8
- mockery/mockery: ^1.1
- phpunit/phpunit: ^8
Requires (Dev)
- php: >=7.2
- philippwitzmann/codingstandard: ^3.0.0.1
This package is auto-updated.
Last update: 2024-09-29 04:37:17 UTC
README
此库旨在提供编写测试的基本功能。
安装
composer require --dev philippwitzmann/testing
用法
创建新的测试文件
<?php use PhilippWitzmann\Testing\TestCase; class SomeClassTest extends TestCase { protected function setUpTest() { // Do Initialisation for your mocks and subject here } protected function tearDownTest() { // Revert any leftovers from your tests } public function testSomething() { $this->assertTrue(true); } }
运行测试
phpunit --configuration config/phpunit.xml
检查代码风格
phpcs