Foundation / checks (deploy) (push) Successful in 5s
Foundation / checks (ecs) (push) Successful in 2m1s
Foundation / checks (network) (push) Successful in 12m13s
Foundation / checks (client) (push) Successful in 14m28s
Foundation / checks (tsan) (push) Successful in 7m56s
Foundation / checks (checks) (push) Successful in 32m49s
Foundation / postgres-tools (push) Canceled after 0s
Foundation / server-image (push) Canceled after 0s
Foundation / image (push) Canceled after 0s
Foundation / checks (postgres) (push) Canceled after 40m58s
EXPERIMENT (ADR-0094), not an organism movement rule: one non-biological marker per session, moved by admitted intentions with a shared integer rule (probe-motion-v1, 100 mm per tick, clamped to the area), held in region memory only. - ProbeMarkers: spawn, area, bounded per-marker schedule, catch-up bound - session protocol v3: marker records in snapshot chunks; the own marker is always sent with its applied sequence and area; v1 and v2 are refused - MotionPredictor (bounded replay from the authoritative marker, corrections, error samples), CorrectionSmoother and InputLead - tests: exact prediction with enough lead, refusal and lead adaptation, lost inputs, bounds, marker records through the codec Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
34 lines
1.1 KiB
C++
34 lines
1.1 KiB
C++
#pragma once
|
|
#include <expected>
|
|
#include <optional>
|
|
#include <source_location>
|
|
#include <stdexcept>
|
|
#include <string>
|
|
|
|
namespace evo::network_test {
|
|
inline void check(bool ok, std::source_location at = std::source_location::current()) {
|
|
if (!ok)
|
|
throw std::runtime_error(std::string{"network "} + at.file_name() + ":" +
|
|
std::to_string(at.line()));
|
|
}
|
|
// The value of an optional that the test requires to be present.
|
|
template <typename T>
|
|
const T& must(const std::optional<T>& o,
|
|
std::source_location at = std::source_location::current()) {
|
|
if (!o)
|
|
throw std::runtime_error(std::string{"network missing value "} + at.file_name() + ":" +
|
|
std::to_string(at.line()));
|
|
return *o;
|
|
}
|
|
template <typename T, typename E> bool refused(const std::expected<T, E>& r, E e) {
|
|
return !r && r.error() == e;
|
|
}
|
|
void protocol_tests();
|
|
void tls_tests();
|
|
void session_tests();
|
|
void control_tests();
|
|
void replication_tests();
|
|
void motion_tests();
|
|
} // namespace evo::network_test
|
|
#define CHECK(...) ::evo::network_test::check(static_cast<bool>(__VA_ARGS__))
|