@@ -543,7 +543,7 @@ def unwind(transaction):
543543@pytest .mark .parametrize (
544544 "test_script, database" ,
545545 [
546- ("v4x0/tx_pull_2_discard_all_port_9001.script" , "test" ), # TODO: Fix correct new behaviour with qid
546+ ("v4x0/tx_pull_2_discard_all_port_9001.script" , "test" ),
547547 ]
548548)
549549def test_bolt_driver_explicit_transaction_consume_result_case_a (driver_info , test_script , database ):
@@ -561,7 +561,7 @@ def test_bolt_driver_explicit_transaction_consume_result_case_a(driver_info, tes
561561@pytest .mark .parametrize (
562562 "test_script, database" ,
563563 [
564- ("v4x0/tx_pull_2_discard_all_port_9001.script" , "test" ), # TODO: Fix correct new behaviour with qid
564+ ("v4x0/tx_pull_2_discard_all_port_9001.script" , "test" ),
565565 ]
566566)
567567def test_bolt_driver_explicit_transaction_consume_result_case_b (driver_info , test_script , database ):
@@ -575,3 +575,21 @@ def test_bolt_driver_explicit_transaction_consume_result_case_b(driver_info, tes
575575 result = transaction .run ("UNWIND [1,2,3,4] AS x RETURN x" )
576576 result .consume ()
577577 transaction .commit ()
578+
579+
580+ @pytest .mark .parametrize (
581+ "test_script" ,
582+ [
583+ "v4x1/return_1_noop_port_9001.script" ,
584+ ]
585+ )
586+ def test_direct_can_handle_noop (driver_info , test_script ):
587+ # python -m pytest tests/stub/test_directdriver.py -s -v -k test_direct_can_handle_noop
588+ with StubCluster (test_script ):
589+ uri = "bolt://127.0.0.1:9001"
590+ with GraphDatabase .driver (uri , auth = driver_info ["auth_token" ], ** driver_config ) as driver :
591+ assert isinstance (driver , BoltDriver )
592+ with driver .session (fetch_size = 2 , default_access_mode = READ_ACCESS ) as session :
593+ result = session .run ("RETURN 1 AS x" )
594+ value = result .single ().value ()
595+ assert value == 1
0 commit comments