mirror of https://github.com/rails/rails
Add spec to verify that MessageDelivery Job accepts priority
This commit is contained in:
parent
b91daea9ff
commit
fa251d9e48
|
@ -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
|
||||
|
|
Loading…
Reference in New Issue