Faultline API Reference

All Types / Faultline.Testing

class SimRunner

public static class SimRunner

Multi-seed exploration, single-seed replay, and determinism assertion helpers for Faultline tests.

Methods

public static void Explore(
        int seedCount,
        Func<SimWorld, Task> scenario,
        ulong startSeed = 1,
        SimWorldOptions? baseOptions = null)

Runs scenario across seedCount sequential seeds. On the first failure, automatically replays with tracing enabled and throws SimRunFailureException.

public static SimWorld Replay(
        ulong seed,
        Func<SimWorld, Task> scenario,
        SimWorldOptions? baseOptions = null)

Replays a single deterministic seed with tracing enabled by default.

public static T AssertDeterministic<T>(
        ulong seed,
        Func<SimWorld, Task<T>> scenario,
        int runs = 5,
        SimWorldOptions? baseOptions = null)

Runs scenario runs times with the same seed and verifies that every run returns an equal result.