tw2066 / api-docs

MIT License
41 stars 16 forks source link

composer test 报错 #35

Open wjycoder opened 1 week ago

wjycoder commented 1 week ago

环境:hyperf 3.1 php 8.1

composer test 
// 省略......
PHPUnit 10.5.38 by Sebastian Bergmann and contributors.

Runtime:       PHP 8.1.29
Configuration: /workingDir/tmp/pro1/phpunit.xml.dist

[DEBUG] Property dto_default_value_level does not exist in Hyperf\ApiDocs\Swagger\SwaggerConfig
[DEBUG] Property enable does not exist in Hyperf\DTO\DtoConfig
[DEBUG] Property format does not exist in Hyperf\DTO\DtoConfig
[DEBUG] Property output_dir does not exist in Hyperf\DTO\DtoConfig
[DEBUG] Property prefix_url does not exist in Hyperf\DTO\DtoConfig
[DEBUG] Property prefix_swagger_resources does not exist in Hyperf\DTO\DtoConfig
[DEBUG] Property validation_custom_attributes does not exist in Hyperf\DTO\DtoConfig
[DEBUG] Property responses does not exist in Hyperf\DTO\DtoConfig
[DEBUG] Property swagger does not exist in Hyperf\DTO\DtoConfig
E                                                                   1 / 1 (100%)

Time: 00:00.007, Memory: 18.00 MB

There was 1 error:

1) HyperfTest\Cases\ExampleTest::testExample
ErrorException: pcntl_fork() has been disabled for security reasons

/workingDir/tmp/pro1/vendor/hyperf/di/src/ScanHandler/PcntlScanHandler.php:35
/workingDir/tmp/pro1/vendor/tangwei/dto/src/Ast/DtoProxyClass.php:59
/workingDir/tmp/pro1/vendor/tangwei/dto/src/BootApplicationListener.php:32
/workingDir/tmp/pro1/vendor/hyperf/event/src/EventDispatcher.php:37
/workingDir/tmp/pro1/vendor/hyperf/framework/src/ApplicationFactory.php:36
/workingDir/tmp/pro1/vendor/hyperf/di/src/Resolver/FactoryResolver.php:46
/workingDir/tmp/pro1/vendor/hyperf/di/src/Resolver/ResolverDispatcher.php:51
/workingDir/tmp/pro1/vendor/hyperf/di/src/Resolver/DepthGuard.php:68
/workingDir/tmp/pro1/vendor/hyperf/di/src/Resolver/ResolverDispatcher.php:52
/workingDir/tmp/pro1/vendor/hyperf/di/src/Container.php:161
/workingDir/tmp/pro1/vendor/hyperf/di/src/Container.php:62
/workingDir/tmp/pro1/vendor/hyperf/di/src/Container.php:103
/workingDir/tmp/pro1/vendor/hyperf/testing/src/Concerns/InteractsWithContainer.php:114
/workingDir/tmp/pro1/vendor/hyperf/testing/src/TestCase.php:50
/workingDir/tmp/pro1/vendor/hyperf/testing/co-phpunit:77

ERRORS!
Tests: 1, Assertions: 0, Errors: 1.
Script co-phpunit --prepend test/bootstrap.php --colors=always handling the test event returned with error code 2
wjy@qingyuan:/workingDir/tmp/pro1$ 
tw2066 commented 4 days ago

@wjycoder 参考 https://github.com/hyperf/hyperf/issues/4412