tests: fix send_message in post/pool archive helpers.

Since efe5e0e send_message is called with an extra param; fix mocked
send_message to handle this param.
This commit is contained in:
evazion
2017-06-14 13:59:34 -05:00
parent 85fa58cb7c
commit cdef9fda7d
2 changed files with 2 additions and 2 deletions

View File

@@ -1,7 +1,7 @@
module PoolArchiveTestHelper
def mock_pool_archive_service!
mock_sqs_service = Class.new do
def send_message(msg)
def send_message(msg, *options)
_, json = msg.split(/\n/)
json = JSON.parse(json)
prev = PoolArchive.where(pool_id: json["pool_id"]).order("id desc").first

View File

@@ -14,7 +14,7 @@ module PostArchiveTestHelper
def mock_post_archive_service!
mock_sqs_service = Class.new do
def send_message(msg)
def send_message(msg, *options)
_, json = msg.split(/\n/)
json = JSON.parse(json)
json.delete("created_at")