From 0b2197774ccca2a15b01212053143114ee058038 Mon Sep 17 00:00:00 2001 From: "yuuji.yaginuma" Date: Mon, 5 Sep 2016 09:13:24 +0900 Subject: use `descendants` to get class that inherited `ActiveJob::Base` `subclasses` get only child classes. Therefore, if create a job common parent class as `ApplicationJob`, inherited class does not get properly. --- activejob/test/jobs/application_job.rb | 4 ++++ activejob/test/jobs/inherited_job.rb | 5 +++++ 2 files changed, 9 insertions(+) create mode 100644 activejob/test/jobs/application_job.rb create mode 100644 activejob/test/jobs/inherited_job.rb (limited to 'activejob/test/jobs') diff --git a/activejob/test/jobs/application_job.rb b/activejob/test/jobs/application_job.rb new file mode 100644 index 0000000000..4a78b890ec --- /dev/null +++ b/activejob/test/jobs/application_job.rb @@ -0,0 +1,4 @@ +require_relative "../support/job_buffer" + +class ApplicationJob < ActiveJob::Base +end diff --git a/activejob/test/jobs/inherited_job.rb b/activejob/test/jobs/inherited_job.rb new file mode 100644 index 0000000000..60fca66f88 --- /dev/null +++ b/activejob/test/jobs/inherited_job.rb @@ -0,0 +1,5 @@ +require_relative "application_job" + +class InheritedJob < ApplicationJob + self.queue_adapter = :inline +end -- cgit v1.2.3