Implement M6.7 bounded environmental interval scheduling
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
#include "evo/core/random.hpp"
|
||||
#include "evo/processes/environmental_community.hpp"
|
||||
#include "evo/processes/environmental_schedule.hpp"
|
||||
#include <algorithm>
|
||||
#include <chrono>
|
||||
#include <cstdio>
|
||||
@@ -340,6 +341,10 @@ void exhausted_tick() {
|
||||
CHECK((*restored)->advance(maximum, input)); // exact retry remains legal
|
||||
CHECK(!(*restored)->advance(0, input)); // cannot wrap
|
||||
CHECK(!(*restored)->advance(maximum - 64, input)); // outside retained window
|
||||
auto pause = schedule_environment(**restored, {identity, maximum, maximum, 50000, {}});
|
||||
CHECK(pause && !pause->failure && pause->committed == 0 && pause->last_tick == maximum);
|
||||
auto wrap = schedule_environment(**restored, {identity, maximum, 0, 50000, {&input, 1}});
|
||||
CHECK(!wrap && wrap.error() == EnvironmentalIntervalError::range);
|
||||
CHECK(bytes(**restored) == b);
|
||||
}
|
||||
void sequences(std::uint64_t ticks) {
|
||||
|
||||
Reference in New Issue
Block a user