Add result summary banner and use PHP_BINARY for preflight
This commit is contained in:
@@ -42,8 +42,9 @@ $manifestPath = $candidateRoot . '/' . basename($manifestName);
|
||||
$validator = $projectRoot . '/backend/scripts/validate_grade10_candidate.php';
|
||||
|
||||
// 1. Mandatory gate preflight: identical strict rules, no exceptions.
|
||||
$phpBinary = defined('PHP_BINARY') && PHP_BINARY !== '' ? PHP_BINARY : 'php';
|
||||
$gateJson = shell_exec(
|
||||
'php ' . escapeshellarg($validator) . ' --json --manifest=' . escapeshellarg(basename($manifestName)) . ' 2>/dev/null'
|
||||
escapeshellcmd($phpBinary) . ' ' . escapeshellarg($validator) . ' --json --manifest=' . escapeshellarg(basename($manifestName)) . ' 2>/dev/null'
|
||||
);
|
||||
$gate = json_decode((string) $gateJson, true);
|
||||
if (!is_array($gate) || ($gate['status'] ?? null) !== 'passed') {
|
||||
|
||||
Reference in New Issue
Block a user