[hal,tests] Use waitForProgramStart in tests (#8429)

Change setProgramStarted to accept a boolean so it can be set back to
false by tests. This allows properly waiting for program start in tests.
This commit is contained in:
Peter Johnson
2025-11-29 10:10:01 -08:00
committed by GitHub
parent 32d3ec0218
commit a4aad63dd4
23 changed files with 84 additions and 49 deletions

View File

@@ -18,10 +18,23 @@ namespace wpi::sim {
*/
void SetRuntimeType(HAL_RuntimeType type);
/**
* Waits until the user program has started.
*/
void WaitForProgramStart();
void SetProgramStarted();
/**
* Sets flag that indicates if the user program has started.
*
* @param started true if started
*/
void SetProgramStarted(bool started);
/**
* Returns true if the user program has started.
*
* @return True if the user program has started.
*/
bool GetProgramStarted();
/**