Files
improvise/crates/improvise-incremental/tests/random_pushdown.rs
T

23 lines
815 B
Rust

//! `Pushdown` over a remote table against `Eager` over random formula and cell edits (NaN,
//! `-0.0`, cycles and text among them). Evidence: `context/test-evidence/improvise-incremental.md`.
mod support;
use improvise_incremental::differential_in;
use proptest::prelude::*;
use support::remote::Pushed;
use support::{any_formula_edit, formula_workbook};
proptest! {
#[test]
fn a_pushdown_matches_eager_over_random_formula_and_cell_edits(
edits in prop::collection::vec(any_formula_edit(), 0..3),
) {
let wb = formula_workbook();
let none = vec!["Region".to_string()];
let candidate = Pushed::new(&wb.model, none.clone());
let ran = differential_in(&wb.model, &[], &none, candidate, &edits);
prop_assert!(ran.is_ok(), "{}", ran.unwrap_err());
}
}