aboutsummaryrefslogtreecommitdiffstats
path: root/activejob
diff options
context:
space:
mode:
authorGannon McGibbon <gannon.mcgibbon@gmail.com>2019-03-25 01:31:17 -0400
committerGannon McGibbon <gannon.mcgibbon@gmail.com>2019-03-25 01:31:48 -0400
commitdbd1db91d9c23c69614940d64fadba78bf925f50 (patch)
tree94dda251edbba371409a09639852a170d5eec863 /activejob
parent6a5c8b91998c56e50b5cc934d968947cd319f735 (diff)
downloadrails-dbd1db91d9c23c69614940d64fadba78bf925f50.tar.gz
rails-dbd1db91d9c23c69614940d64fadba78bf925f50.tar.bz2
rails-dbd1db91d9c23c69614940d64fadba78bf925f50.zip
Fix assert_performed_with time tests
Diffstat (limited to 'activejob')
-rw-r--r--activejob/test/cases/test_helper_test.rb18
1 files changed, 9 insertions, 9 deletions
diff --git a/activejob/test/cases/test_helper_test.rb b/activejob/test/cases/test_helper_test.rb
index d6607cb6b6..32471cfacc 100644
--- a/activejob/test/cases/test_helper_test.rb
+++ b/activejob/test/cases/test_helper_test.rb
@@ -1710,28 +1710,28 @@ class PerformedJobsTest < ActiveJob::TestCase
def test_assert_performed_with_time
now = Time.now
- args = [{ argument1: { now: now } }]
+ args = [{ argument1: { now: now }, argument2: now }]
- assert_enqueued_with(job: MultipleKwargsJob, args: args) do
- MultipleKwargsJob.perform_later(argument1: { now: now })
+ assert_performed_with(job: MultipleKwargsJob, args: args) do
+ MultipleKwargsJob.perform_later(argument1: { now: now }, argument2: now)
end
end
def test_assert_performed_with_date_time
now = DateTime.now
- args = [{ argument1: { now: now } }]
+ args = [{ argument1: { now: now }, argument2: now }]
- assert_enqueued_with(job: MultipleKwargsJob, args: args) do
- MultipleKwargsJob.perform_later(argument1: { now: now })
+ assert_performed_with(job: MultipleKwargsJob, args: args) do
+ MultipleKwargsJob.perform_later(argument1: { now: now }, argument2: now)
end
end
def test_assert_performed_with_time_with_zone
now = Time.now.in_time_zone("Tokyo")
- args = [{ argument1: { now: now } }]
+ args = [{ argument1: { now: now }, argument2: now }]
- assert_enqueued_with(job: MultipleKwargsJob, args: args) do
- MultipleKwargsJob.perform_later(argument1: { now: now })
+ assert_performed_with(job: MultipleKwargsJob, args: args) do
+ MultipleKwargsJob.perform_later(argument1: { now: now }, argument2: now)
end
end