mirror of
https://github.com/pestphp/pest.git
synced 2026-03-06 15:57:21 +01:00
feat: toHaveAllMethodsDocumented and toHaveAllPropertiesDocumented
This commit is contained in:
13
tests/Features/Expect/toHaveAllMethodsDocumented.php
Normal file
13
tests/Features/Expect/toHaveAllMethodsDocumented.php
Normal file
@ -0,0 +1,13 @@
|
||||
<?php
|
||||
|
||||
use Pest\Arch\Exceptions\ArchExpectationFailedException;
|
||||
use Pest\Expectation;
|
||||
use Tests\Fixtures\Inheritance\ExampleTest;
|
||||
|
||||
it('passes', function () {
|
||||
expect(Expectation::class)->toHaveAllMethodsDocumented();
|
||||
});
|
||||
|
||||
it('fails', function () {
|
||||
expect(ExampleTest::class)->toHaveAllMethodsDocumented();
|
||||
})->throws(ArchExpectationFailedException::class);
|
||||
13
tests/Features/Expect/toHaveAllPropertiesDocumented.php
Normal file
13
tests/Features/Expect/toHaveAllPropertiesDocumented.php
Normal file
@ -0,0 +1,13 @@
|
||||
<?php
|
||||
|
||||
use Pest\Arch\Exceptions\ArchExpectationFailedException;
|
||||
use Pest\Expectation;
|
||||
use Tests\Fixtures\Inheritance\ExampleTest;
|
||||
|
||||
it('passes', function () {
|
||||
expect(Expectation::class)->toHaveAllPropertiesDocumented();
|
||||
});
|
||||
|
||||
it('fails', function () {
|
||||
expect(ExampleTest::class)->toHaveAllPropertiesDocumented();
|
||||
})->throws(ArchExpectationFailedException::class);
|
||||
@ -4,7 +4,7 @@ use Pest\Arch\Exceptions\ArchExpectationFailedException;
|
||||
use Pest\Expectation;
|
||||
|
||||
it('passes', function () {
|
||||
expect(Expectation::class)->toHaveLineCountLessThan(1000);
|
||||
expect(Expectation::class)->toHaveLineCountLessThan(2000);
|
||||
});
|
||||
|
||||
it('fails', function () {
|
||||
|
||||
Reference in New Issue
Block a user