@@ -4873,6 +4873,7 @@ def test_show_add_filter_dialog_sets_show_sql_flag(
48734873 )
48744874 mock_dialog = mocker .Mock ()
48754875 mock_dialog .exec .return_value = 0 # Rejected
4876+ mock_dialog .is_raw = False # Ensure assisted path
48764877 mock_dialog_class .return_value = mock_dialog
48774878
48784879 view ._show_add_filter_dialog ({"db_loader" : "test" })
@@ -4891,6 +4892,7 @@ def test_show_add_filter_dialog_opens_dialog(
48914892 )
48924893 mock_dialog = mocker .Mock ()
48934894 mock_dialog .exec .return_value = 0
4895+ mock_dialog .is_raw = False # Ensure assisted path
48944896 mock_dialog_class .return_value = mock_dialog
48954897
48964898 view ._show_add_filter_dialog ({"db_loader" : "test" })
@@ -4911,6 +4913,7 @@ def test_show_add_filter_dialog_validates_filter_on_accept(
49114913 mock_dialog .exec .return_value = 1 # Accepted
49124914 mock_dialog .name = "NewFilter"
49134915 mock_dialog .filter_text = "WHERE duration > 100"
4916+ mock_dialog .is_raw = False # Ensure assisted path
49144917 mock_dialog_class .return_value = mock_dialog
49154918 view .global_signal = mocker .Mock ()
49164919
@@ -4920,7 +4923,6 @@ def test_show_add_filter_dialog_validates_filter_on_accept(
49204923 call_args = view .global_signal .emit .call_args [0 ]
49214924 assert call_args [2 ] == "construct_metadata_query"
49224925
4923-
49244926def test_show_add_filter_dialog_returns_when_no_loader (
49254927 view : MetadataView , mocker : MockerFixture
49264928) -> None :
@@ -4933,6 +4935,7 @@ def test_show_add_filter_dialog_returns_when_no_loader(
49334935 mock_dialog .exec .return_value = 1
49344936 mock_dialog .name = "NewFilter"
49354937 mock_dialog .filter_text = "WHERE x > 1"
4938+ mock_dialog .is_raw = False # Ensure assisted path
49364939 mock_dialog_class .return_value = mock_dialog
49374940 view .global_signal = mocker .Mock ()
49384941
@@ -5013,6 +5016,7 @@ def test_show_edit_filter_dialog_sets_show_sql_flag(
50135016 )
50145017 mock_dialog = mocker .Mock ()
50155018 mock_dialog .exec .return_value = 0
5019+ mock_dialog .is_raw = False # Ensure assisted path
50165020 mock_dialog_class .return_value = mock_dialog
50175021
50185022 view .show_edit_filter_dialog ("Filter1" , "test_loader" )
@@ -5030,6 +5034,7 @@ def test_show_edit_filter_dialog_opens_dialog(
50305034 )
50315035 mock_dialog = mocker .Mock ()
50325036 mock_dialog .exec .return_value = 0
5037+ mock_dialog .is_raw = False # Ensure assisted path
50335038 mock_dialog_class .return_value = mock_dialog
50345039
50355040 view .show_edit_filter_dialog ("Filter1" , "test_loader" )
@@ -5052,14 +5057,14 @@ def test_show_edit_filter_dialog_validates_on_accept(
50525057 mock_dialog .exec .return_value = 1
50535058 mock_dialog .new_name = "Filter1Updated"
50545059 mock_dialog .new_filter = "WHERE x > 10"
5060+ mock_dialog .is_raw = False # Ensure assisted path
50555061 mock_dialog_class .return_value = mock_dialog
50565062 view .global_signal = mocker .Mock ()
50575063
50585064 view .show_edit_filter_dialog ("Filter1" , "test_loader" )
50595065
50605066 view .global_signal .emit .assert_called_once ()
5061-
5062-
5067+
50635068def test_show_edit_filter_dialog_stores_pending_data_including_old_name (
50645069 view : MetadataView , mocker : MockerFixture
50655070) -> None :
@@ -5072,6 +5077,7 @@ def test_show_edit_filter_dialog_stores_pending_data_including_old_name(
50725077 mock_dialog .exec .return_value = 1
50735078 mock_dialog .new_name = "Filter1Updated"
50745079 mock_dialog .new_filter = "WHERE x > 10"
5080+ mock_dialog .is_raw = False # Ensure assisted path
50755081 mock_dialog_class .return_value = mock_dialog
50765082 view .global_signal = mocker .Mock ()
50775083
0 commit comments