Skip to content

armgit / sure

Public Imported from GitHub
0

The personal finance app for everyone (by everyone)

Ruby

Align Enable Banking test stubs with pagination result contract

SureBotd02c7676ce43
diff --git a/test/models/enable_banking_item/importer_shared_transaction_id_test.rb b/test/models/enable_banking_item/importer_shared_transaction_id_test.rb
index b015c377d3..126d5df549 100644
--- a/test/models/enable_banking_item/importer_shared_transaction_id_test.rb
+++ b/test/models/enable_banking_item/importer_shared_transaction_id_test.rb
@@ -116,10 +116,10 @@ class EnableBankingItem::ImporterSharedTransactionIdTest < ActiveSupport::TestCa
def sync(booked:, pending: nil)
@importer.stubs(:fetch_paginated_transactions)
- .with(@enable_banking_account, has_entries(transaction_status: "BOOK")).returns(booked)
+ .with(@enable_banking_account, has_entries(transaction_status: "BOOK")).returns([ booked, false ])
unless pending.nil?
@importer.stubs(:fetch_paginated_transactions)
- .with(@enable_banking_account, has_entries(transaction_status: "PDNG")).returns(pending)
+ .with(@enable_banking_account, has_entries(transaction_status: "PDNG")).returns([ pending, false ])
end
assert @importer.send(:fetch_and_store_transactions, @enable_banking_account)[:success]