Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

docs(testing): clarify property-test regression guidance

Steven Enamakel9cf637fbb0c8
diff --git a/crates/openhuman-core/src/storage/lease_model_tests.rs b/crates/openhuman-core/src/storage/lease_model_tests.rs
index bf44501b64..d9204277a5 100644
--- a/crates/openhuman-core/src/storage/lease_model_tests.rs
+++ b/crates/openhuman-core/src/storage/lease_model_tests.rs
@@ -319,6 +319,7 @@ fn scenario() -> impl Strategy<Value = (usize, Vec<Op>)> {
(2usize..=4).prop_flat_map(|nodes| (Just(nodes), prop::collection::vec(ops(nodes), 1..80)))
}
+/// Preserve the saved lease-model case: the same holder reacquires at exact expiry.
#[tokio::test]
async fn reacquiring_at_expiry_advances_epoch_and_marks_previous_holder_unclean() {
run(2, vec![Op::Acquire(0), Op::Advance(1_000), Op::Acquire(0)])
diff --git a/gitbooks/developing/testing-strategy.md b/gitbooks/developing/testing-strategy.md
index bf4fc31501..6cc75d9c21 100644
--- a/gitbooks/developing/testing-strategy.md
+++ b/gitbooks/developing/testing-strategy.md
@@ -55,7 +55,7 @@ A spec that asserts only the happy path is incomplete.
## Property-test regressions
-Core proptests set `failure_persistence: None` in their `ProptestConfig`; they do not write seed files. When a property fails, keep the seed from the failure output to reproduce it, then promote the shrunk input to a named unit test beside the property test. Confirm that the explicit case fails against the faulty implementation and passes with the fix before shipping it.
+Core proptests set `failure_persistence: None` in their `ProptestConfig`; they do not write seed files. When a property fails, preserve the minimized input shown in the failure report to reproduce it, then promote that input to a named unit test beside the property test. Confirm that the explicit case fails against the faulty implementation and passes with the fix before shipping it.
For example, the lease model retains the expired-holder reacquisition case as `reacquiring_at_expiry_advances_epoch_and_marks_previous_holder_unclean`, with two nodes and the steps `Acquire(0), Advance(1000), Acquire(0)`.