aboutsummaryrefslogtreecommitdiffstats
path: root/activejob/test/support/queue_classic/inline.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activejob/test/support/queue_classic/inline.rb')
-rw-r--r--activejob/test/support/queue_classic/inline.rb12
1 files changed, 12 insertions, 0 deletions
diff --git a/activejob/test/support/queue_classic/inline.rb b/activejob/test/support/queue_classic/inline.rb
index 5e9c295e01..5743d5bbb5 100644
--- a/activejob/test/support/queue_classic/inline.rb
+++ b/activejob/test/support/queue_classic/inline.rb
@@ -7,5 +7,17 @@ module QC
receiver = eval(receiver_str)
receiver.send(message, *args)
end
+
+ def enqueue_in(seconds, method, *args)
+ receiver_str, _, message = method.rpartition('.')
+ receiver = eval(receiver_str)
+ receiver.send(message, *args)
+ end
+
+ def enqueue_at(not_before, method, *args)
+ receiver_str, _, message = method.rpartition('.')
+ receiver = eval(receiver_str)
+ receiver.send(message, *args)
+ end
end
end