Skip to content

Commit 8cfaffd

Browse files
committed
Added unit tests.
1 parent 868b36c commit 8cfaffd

File tree

9 files changed

+2106
-237
lines changed

9 files changed

+2106
-237
lines changed

.php-censor.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ setup:
88
action: install
99

1010
test:
11+
php_unit:
12+
config:
13+
- phpunit.xml.dist
14+
coverage: true
15+
1116
php_mess_detector:
1217
allow_failures: true
1318

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,14 @@ none | --no-ansi | Disable ANSI output.
4343
-n | --no-interaction | Do not ask any interactive question.
4444
-v -vv -vvv | --verbose | Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug.
4545

46+
## Unit tests
47+
48+
Phpunit tests:
49+
50+
```bash
51+
vendor/bin/phpunit --configuration=phpunit.xml.dist --coverage-text --coverage-html=tests/var/coverage
52+
```
53+
4654
## License
4755

4856
PHPDoc Checker is open source software licensed under the [BSD-2-Clause license](LICENSE).

composer.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,11 @@
2929
"PhpDocChecker\\": "src/"
3030
}
3131
},
32+
"autoload-dev": {
33+
"psr-4": {
34+
"Tests\\PhpDocChecker\\": "tests/src"
35+
}
36+
},
3237
"require": {
3338
"php": ">=7.1.0",
3439
"ext-json": "*",
@@ -37,6 +42,7 @@
3742
"symfony/console": "^4.4"
3843
},
3944
"require-dev": {
45+
"phpunit/phpunit": "^7.5",
4046
"phpmd/phpmd": "^2.10",
4147
"sebastian/phpcpd": "^4.0",
4248
"squizlabs/php_codesniffer": "^3.6",

0 commit comments

Comments
 (0)