From 3e8867c8f5e46a47d7cc7821471e1c60a2f37c00 Mon Sep 17 00:00:00 2001 From: pedrocarlo Date: Mon, 6 Oct 2025 00:10:55 -0300 Subject: [PATCH] `DropSelect` property should only fail when error is not a parse error on the table name --- simulator/generation/property.rs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/simulator/generation/property.rs b/simulator/generation/property.rs index 5ad72c5c6..ff7856474 100644 --- a/simulator/generation/property.rs +++ b/simulator/generation/property.rs @@ -691,21 +691,21 @@ impl Property { format!("select query should result in an error for table '{table}'"), move |stack: &Vec, _| { let last = stack.last().unwrap(); + dbg!(last); match last { Ok(success) => Ok(Err(format!( "expected table creation to fail but it succeeded: {success:?}" ))), - Err(e) => { - if e.to_string() - .contains(&format!("Table {table_name} does not exist")) + Err(e) => match e { + LimboError::ParseError(e) + if e.contains(&format!("no such table: {table_name}")) => { Ok(Ok(())) - } else { - Ok(Err(format!( - "expected table does not exist error, got: {e}" - ))) } - } + _ => Ok(Err(format!( + "expected table does not exist error, got: {e}" + ))), + }, } }, )); @@ -726,7 +726,7 @@ impl Property { .into_iter() .map(|q| Interaction::new(connection_index, InteractionType::Query(q))), ); - interactions.push(Interaction::new(connection_index, select)); + interactions.push(Interaction::new_ignore_error(connection_index, select)); interactions.push(Interaction::new(connection_index, assertion)); interactions