Files
wp-asciiplayer/tests/php/cast-budget-decoder.php
T
LamGC e1cd87f87d fix: bound recording timestamps before playback
Match upstream millisecond accumulation and bound native timer horizons.
Add deterministic rounding, overflow and non-progress regression casts,
with captured-player and WordPress playback/upload coverage.
2026-10-15 11:30:31 +08:00

12 lines
460 B
PHP

<?php
/** Test-only decoder instrumentation, loaded before production calls. */
namespace LamGC\Asciiplayer {
// Instrument the real decoder without adding a production test hook. A gate
// failure must not build the rejected whole-document object graph.
function json_decode( $json, $associative = null, $depth = 512, $flags = 0 ) {
$GLOBALS['cast_decode_lengths'][] = strlen( $json );
return \json_decode( $json, $associative, $depth, $flags );
}
}