State testability

Separates various concepts into discrete entities and adds a coroutine callback for testing.
Also, removes the "Execution started" event, because it was mostly there for testing.