PASSES_TRUNCATION_SENTINEL_NAME

Constant PASSES_TRUNCATION_SENTINEL_NAME 

Source
pub const PASSES_TRUNCATION_SENTINEL_NAME: &str = "__ktstr_passes_truncated__";
Expand description

Sentinel PassDetail.name value used by the truncation record that replaces the MAX_RECORDED_PASSES-th slot when a test over-runs the cap. Consumers (the auto-repro renderer) match on this string to render [N passes truncated] instead of treating it as a real claim.

Truncation-check idiom: a caller checking result.passes.len() == MAX_RECORDED_PASSES MISSES the truncated state because the truncation sentinel pushes the vec to MAX_RECORDED_PASSES + 1. The correct check is result.passes.last().map(|p| p.name == PASSES_TRUNCATION_SENTINEL_NAME) .unwrap_or(false) — i.e. inspect the tail entry’s name.