vendor/phpunit/php-code-coverage/src/CodeCoverage/Driver/PHPDBG.php
(开头部分) 1KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
<?php
/*
* This file is part of the PHP_CodeCoverage package.
*
* (c) Sebastian Bergmann <sebastian@phpunit.de>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
/**
* Driver for PHPDBG's code coverage functionality.
*
* @since Class available since Release 2.2.0
* @codeCoverageIgnore
*/
class PHP_CodeCoverage_Driver_PHPDBG implements PHP_CodeCoverage_Driver
{
/**
* Constructor.
*/
public function __construct()
{
if (PHP_SAPI !== 'phpdbg') {
throw new PHP_CodeCoverage_Exception(
'This driver requires the PHPDBG SAPI'
);
}
if (!function_exists('phpdbg_start_oplog')) {
throw new PHP_CodeCoverage_Exception(
'This build of PHPDBG does not support code coverage'
);
}
}
/**
* Start collection of code coverage information.
*/
public function start()
{
phpdbg_start_oplog();
}
/**
* Stop collection of code coverage information.
*
* @return array
*/
public function stop()
{
static $fetchedLines = array();
$dbgData = phpdbg_end_oplog();
if ($fetchedLines == array()) {
$sourceLines = phpdbg_get_executable();
} else {
$newFiles = array_diff(
get_included_files(),
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。