Skip to content

Commit 9b72051

Browse files
committed
disable some integrations and skip some tests
after removing Ordering BC. Next steps: * fix customers read model * enable and fix payments integration (after Fulfillment::OrderRegisterd) * enable and fix invoicing integration * ensure shipping still works * fix Refunds * raname Pricing commands PriceItemAdded, PriceItemRemoved to OfferItemAdded, OfferItemRemoved * kill mutants * fix 3+1 process and integrate it into rails_application
1 parent f871b08 commit 9b72051

File tree

7 files changed

+19
-5
lines changed

7 files changed

+19
-5
lines changed

ecommerce/fulfillment/test/register_order_test.rb

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,11 @@ class ConfirmOrderTest < Test
77
def test_new_order_can_be_registered
88
aggregate_id = SecureRandom.uuid
99
stream = "Fulfillment::Order$#{aggregate_id}"
10+
order_number = FakeNumberGenerator::FAKE_NUMBER
1011

1112
assert_events(
1213
stream,
13-
OrderRegistered.new(data: { order_id: aggregate_id })
14+
OrderRegistered.new(data: { order_id: aggregate_id, order_number: })
1415
) { act(RegisterOrder.new(order_id: aggregate_id)) }
1516
end
1617

@@ -26,4 +27,4 @@ def test_registered_order_can_not_be_registered_again
2627
end
2728
end
2829
end
29-
end
30+
end

ecommerce/fulfillment/test/test_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ module Fulfillment
77
class Test < Infra::InMemoryTest
88
def before_setup
99
super
10-
Configuration.new.call(event_store, command_bus)
10+
Configuration.new(-> { FakeNumberGenerator.new }).call(event_store, command_bus)
1111
end
1212
end
1313
end

ecommerce/processes/test/determine_vat_rate_test.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ class DetermineVatRateTest < Test
55
cover "Processes::DetermineVatRatesOnOrderPlaced*"
66

77
def test_inventory_available_error_is_raised
8+
skip
89
product_id = SecureRandom.uuid
910
order_id = SecureRandom.uuid
1011
process = DetermineVatRatesOnOrderPlaced.new(command_bus)

ecommerce/processes/test/order_item_invoicing_process_test.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ class OrderItemInvoicingProcessTest < Test
55
cover "Processes::OrderItemInvoicingProcess*"
66

77
def test_invoice_item_being_created
8+
skip "Invoicing BC not yet re-implemented"
89
product_id = SecureRandom.uuid
910
amount = 100.to_d
1011
discounted_amount = 90.to_d
@@ -40,4 +41,4 @@ def test_invoice_item_being_created
4041
))
4142
end
4243
end
43-
end
44+
end

ecommerce/processes/test/release_payment_process_test.rb

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ module Processes
44
class ReleasePaymentProcessTest < Test
55
cover "Processes::ReleasePaymentProcess*"
66

7+
def setup
8+
skip "ReleasePaymentProcess not yet re-implemented without Ordering BC"
9+
end
10+
711
def test_happy_path
812
process = ReleasePaymentProcess.new(event_store, command_bus)
913
given([order_placed, payment_authorized, order_confirmed]).each do |event|
@@ -34,4 +38,4 @@ def test_order_expired_after_payment_released
3438
assert_no_command
3539
end
3640
end
37-
end
41+
end

rails_application/test/orders/item_added_to_refund_test.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ module Refunds
44
class ItemAddedToRefundTest < InMemoryTestCase
55
cover "Orders*"
66

7+
def setup
8+
skip "Refunds are not integrated yet"
9+
end
10+
711
def test_add_item_to_refund
812
refund_id = SecureRandom.uuid
913
product_id = SecureRandom.uuid

rails_application/test/orders/item_removed_from_refund_test.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ module Refunds
44
class ItemRemovedFromRefundTest < InMemoryTestCase
55
cover "Orders*"
66

7+
def setup
8+
skip "Refunds are not integrated yet"
9+
end
710
def test_remove_item_from_refund
811
refund_id = SecureRandom.uuid
912
product_id = SecureRandom.uuid

0 commit comments

Comments
 (0)