* [uitest] add ui test coverage report.

This commit is contained in:
liyang
2025-05-22 13:56:41 +08:00
committed by 李阳
parent 1e8a203cec
commit 248d3b356c
+11
View File
@@ -252,6 +252,17 @@ class coverage
foreach($lines as $line)
{
$trimmed = trim($line);
// 跳过class定义行
if(preg_match('/^class\s+/i', $trimmed)) continue;
// 跳过function定义行
if(strpos($trimmed, 'function') !== false) continue;
// 跳过php定义行
if(strpos($trimmed, '<?php') !== false || strpos($trimmed, '?>') !== false) continue;
}
return $lineCount;