Automated beta trace record/replay for gameplay testing#235
Draft
timfox wants to merge 1 commit into
Draft
Conversation
Implement client-side beta trace framework inspired by Hernández et al. (Entertainment Computing 2017): record usercmds and JSONL high-level events, replay for regression tests, and evaluate success/fail patterns with timeouts. Includes documentation, demo_game example traces, Petri net JSON sample, and CTest format validation script. Co-authored-by: Tim Fox <timfox@outlook.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a chocolate-layer beta trace framework on the client, inspired by Hernández Bécares et al. (An approach to automated videogame beta testing, Entertainment Computing 18, 2017). It supports recording and replaying gameplay for regression testing without relying on a full component/message-passing architecture.
What changed
src/client/cl_beta_trace.c: recordusercmd_tstreams (.betacmd), high-level JSONL events (.betaevt), and test manifests (.betatest); replay viabeta_play/beta_testwith success/fail pattern matching andmax_time_ms.cl_input.c(cmd injection),cl_cgame.c(map_loadedevents),cl_main.c(init + per-frame timeout).docs/BETA_AUTOMATED_TESTING.mdexamples/demo_game/beta_traces/including a Petri-net JSON sample for switch-held doors (paper Fig. 10 style).tests/scripts/test_beta_trace_format.sh+ CTesttest_beta_trace_formatConsole API
beta_record/beta_stopbeta_traces/beta_playbeta_testbeta_eventCvars:
cl_betaTrace(default 1),cl_betaTraceLog(startup log).Out of scope (follow-up)
Validation
./tests/scripts/test_beta_trace_format.sh— passidtech3links withbeta_*commands