From dc58697e4bc5d2cc1e63c7bdc52f53618992915c Mon Sep 17 00:00:00 2001 From: marlena-b Date: Mon, 16 Sep 2024 18:11:31 +0200 Subject: [PATCH] Fix test --- .../test/services/client/orders/submit_service_test.rb | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/rails_application/test/services/client/orders/submit_service_test.rb b/rails_application/test/services/client/orders/submit_service_test.rb index dcc7eafe..412351d2 100644 --- a/rails_application/test/services/client/orders/submit_service_test.rb +++ b/rails_application/test/services/client/orders/submit_service_test.rb @@ -14,7 +14,12 @@ def test_successful_order_submission prepare_product(product_id, "Async Remote", 49) run_command(Ordering::AddItemToBasket.new(order_id: order_id, product_id: product_id)) - assert_equal true, SubmitService.new(order_id: order_id, customer_id: customer_id).call + Client::Orders::SubmitService.new(order_id: order_id, customer_id: customer_id).call + + order = ClientOrders::Order.find_by!(order_uid: order_id) + + assert_equal "Submitted", order.state + assert_equal customer_id, order.client_uid end def test_order_submission_with_unavailable_products