Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit8184473

Browse files
committed
Tests fixes
1 parentd0f3e19 commit8184473

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

‎tests/test_trace_session.py‎

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -477,13 +477,13 @@ def trace_session_plpgsql_functions(node: PostgresNode):
477477
withnode.connect("postgres",autocommit=True)asconn:
478478
start_session_trace(conn)
479479

480-
assertnode.execute("select calculate_order_total(2)")== [(Decimal('80000.00'),)]
481-
node.execute("select update_order_status(2, 'SHIPPED')")
482-
node.execute("select add_product_to_order(1, 2, 100)")
483-
assertnode.execute("select * from get_user_orders(1)")== [(1,Decimal('4050000.00'),'NEW',2,)]
484-
node.execute("select create_user('aboba', 'boba', 'aboba_boba@example.ru', '+79132281337')")
485-
assertnode.execute("select * from get_low_stock_products(10000)")== [(2,"Samsung Galaxy S10",50,40000.00),(1,"iPhone X",100,50000.00), (3,"Xiaomi Redmi Note 8 Pro",200,25000.00)]
486-
assertnode.execute("SELECT process_complete_order(1, ARRAY[2,3], ARRAY[10, 5])")== [(4,)]
480+
assertconn.execute("select calculate_order_total(2)")== [(Decimal('80000.00'),)]
481+
conn.execute("select update_order_status(2, 'SHIPPED')")
482+
conn.execute("select add_product_to_order(1, 2, 100)")
483+
assertconn.execute("select * from get_user_orders(1)")== [(1,Decimal('4050000.00'),'NEW',2,)]
484+
conn.execute("select create_user('aboba', 'boba', 'aboba_boba@example.ru', '+79132281337')")
485+
assertconn.execute("select * from get_low_stock_products(10000)")== [(2,"Samsung Galaxy S10",50,40000.00),(1,"iPhone X",100,50000.00), (3,"Xiaomi Redmi Note 8 Pro",200,25000.00)]
486+
assertconn.execute("SELECT process_complete_order(1, ARRAY[2,3], ARRAY[10, 5])")== [(4,)]
487487

488488
stop_session_trace(conn)
489489

@@ -510,9 +510,9 @@ def trace_session_correct_executor_finish(node: PostgresNode):
510510
withnode.connect("postgres",autocommit=True)asconn:
511511
start_session_trace(conn)
512512

513-
node.execute("create table mlparted (a int, b int)")
513+
conn.execute("create table mlparted (a int, b int)")
514514

515-
node.execute("with ins (a, b, c) as\
515+
conn.execute("with ins (a, b, c) as\
516516
(insert into mlparted (b, a) select s.a, 1 from generate_series(2, 39) s(a) returning tableoid::regclass, *)\
517517
select a, b, min(c), max(c) from ins group by a, b order by 1;")
518518

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp