1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/test/cases/queuing_test.rb
2014-05-18 12:32:22 +02:00

19 lines
358 B
Ruby

require 'helper'
require 'jobs/hello_job'
class QueuingTest < ActiveSupport::TestCase
setup do
$BUFFER = []
end
test 'run queued job' do
HelloJob.enqueue
assert_equal "David says hello", $BUFFER.pop
end
test 'run queued job with parameters' do
HelloJob.enqueue "Jamie"
assert_equal "Jamie says hello", $BUFFER.pop
end
end