From fa251d9e4800c6860947c534fd855d46b2960536 Mon Sep 17 00:00:00 2001 From: Vipul A M Date: Mon, 22 Jun 2020 22:31:15 +0530 Subject: [PATCH] Add spec to verify that MessageDelivery Job accepts priority --- actionmailer/test/message_delivery_test.rb | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/actionmailer/test/message_delivery_test.rb b/actionmailer/test/message_delivery_test.rb index 09eb0c70f65..7649aae3593 100644 --- a/actionmailer/test/message_delivery_test.rb +++ b/actionmailer/test/message_delivery_test.rb @@ -83,6 +83,11 @@ class MessageDeliveryTest < ActiveSupport::TestCase end end + test "should enqueue a delivery with a priority" do + job = @mail.deliver_later priority: 10 + assert_equal 10, job.priority + end + test "should enqueue a delivery at a specific time" do later_time = Time.current + 1.hour assert_performed_with(job: ActionMailer::MailDeliveryJob, at: later_time, args: ["DelayedMailer", "test_message", "deliver_now", args: [1, 2, 3]]) do