Skip to content

Commit

Permalink
fix test to be false or null, not true
Browse files Browse the repository at this point in the history
  • Loading branch information
wjones127 committed Sep 11, 2023
1 parent 4bd9b60 commit 16d78c6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3271,7 +3271,7 @@ mod tests {
let output = simplify_with_guarantee(expr.clone(), &guarantees);
assert_eq!(output, lit(false));

// Guaranteed true or null -> no change.
// Guaranteed false or null -> no change.
let guarantees = vec![
(
col("c3"),
Expand All @@ -3283,7 +3283,7 @@ mod tests {
(
col("c4"),
NullableInterval {
values: Interval::make(Some(0_u32), Some(5_u32), (false, false)),
values: Interval::make(Some(9_u32), Some(9_u32), (false, false)),
is_valid: Interval::UNCERTAIN,
},
),
Expand Down
8 changes: 4 additions & 4 deletions datafusion/physical-expr/src/intervals/interval_aritmetic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -743,19 +743,19 @@ enum NullStatus {
/// NullableInterval {
/// values: Interval::make(Some(1), Some(2), (false, true)),
/// is_valid: Interval::UNCERTAIN,
/// }
/// };
///
/// // (0, ∞)
/// NullableInterval {
/// values: Interval::make(Some(0), None, (true, true)),
/// is_valid: Interval::CERTAINLY_TRUE,
/// }
/// };
///
/// // {NULL}
/// NullableInterval::from(ScalarValue::Int32(None))
/// NullableInterval::from(&ScalarValue::Int32(None));
///
/// // {4}
/// NullableInterval::from(ScalarValue::Int32(4))
/// NullableInterval::from(&ScalarValue::Int32(Some(4)));
/// ```
#[derive(Debug, Clone, PartialEq, Eq, Default)]
pub struct NullableInterval {
Expand Down

0 comments on commit 16d78c6

Please sign in to comment.