1. 01 2月, 2017 1 次提交
    • Y
      correctly set test adapter when configure the queue adapter on a per job (#26690) · 80dc3098
      Yuji Yaginuma 提交于
      The `ActiveJob::TestHelper` replace the adapter to test adapter in
      `before_setup`. It gets the target class using the `descendants`, but if
      the test target job class is not loaded, will not be a replacement of
      the adapter.
      Therefore, instead of replacing with `before_setup`, modified to
      replace when setting adapter.
      
      Fixes #26360
      80dc3098
  2. 31 1月, 2017 1 次提交
  3. 11 10月, 2016 2 次提交
  4. 09 10月, 2016 1 次提交
  5. 19 8月, 2016 1 次提交
  6. 17 8月, 2016 1 次提交
  7. 10 8月, 2016 1 次提交
  8. 03 8月, 2016 1 次提交
  9. 10 5月, 2016 1 次提交
  10. 07 5月, 2016 1 次提交
  11. 29 4月, 2016 1 次提交
  12. 28 4月, 2016 1 次提交
  13. 01 3月, 2016 2 次提交
  14. 25 2月, 2016 1 次提交
  15. 05 2月, 2016 1 次提交
  16. 02 2月, 2016 1 次提交
  17. 23 12月, 2015 1 次提交
  18. 21 12月, 2015 1 次提交
    • G
      No more no changes entries in the CHANGELOGs · c5b6ec7b
      Genadi Samokovarov 提交于
      During the `5.0.0.beta1` release, the CHANGELOGs got an entry like the
      following:
      
      ```
      * No changes.
      ```
      
      It is kinda confusing as there are indeed changes after it. Not a
      biggie, just a small pass over the CHANGELOGs.
      
      [ci skip]
      c5b6ec7b
  19. 19 12月, 2015 1 次提交
  20. 03 10月, 2015 2 次提交
  21. 18 9月, 2015 1 次提交
  22. 26 8月, 2015 1 次提交
  23. 13 8月, 2015 1 次提交
  24. 11 8月, 2015 1 次提交
  25. 04 8月, 2015 1 次提交
    • J
      Fixes #20799 · 3860e6b2
      Johannes Opper 提交于
      When `#perform_later` is called the locale isn't stored on the
      queue, which results in a locale reset when the job is performed.
      
      An example of the problem:
      
          I18n.locale = 'de'
          HelloJob.perform_now # german message, correct
      
      but
      
          I18n.locale = 'de'
          HelloJob.perform_later # english message, incorrect
      
      This PR attaches the current I18n.locale to every job during the
      serialization process. It is then restored during deserialization
      and used to perform the job with the correct locale.
      
      It falls back to the default locale if no serialized locale is
      found in order to provide backward compatibility with previously
      stored jobs. It is not necessary to clear the queue for the update.
      3860e6b2
  26. 31 5月, 2015 1 次提交
  27. 16 5月, 2015 1 次提交
  28. 08 5月, 2015 3 次提交
  29. 05 5月, 2015 1 次提交
  30. 24 3月, 2015 1 次提交
  31. 08 2月, 2015 1 次提交
  32. 07 2月, 2015 1 次提交
    • M
      Add an `:only` option to `perform_enqueued_jobs` to filter jobs based on · e818f657
      Michael Ryan 提交于
      type.
      
      This allows specific jobs to be tested, while preventing others from
      being performed unnecessarily.
      
      Example:
      
          def test_hello_job
            assert_performed_jobs 1, only: HelloJob do
              HelloJob.perform_later('jeremy')
              LoggingJob.perform_later
            end
          end
      
      An array may also be specified, to support testing multiple jobs.
      
      Example:
      
          def test_hello_and_logging_jobs
            assert_nothing_raised do
              assert_performed_jobs 2, only: [HelloJob, LoggingJob] do
                HelloJob.perform_later('jeremy')
                LoggingJob.perform_later('stewie')
                RescueJob.perform_later('david')
              end
            end
          end
      
      Fixes #18802.
      
      Trim space and document :only option.
      e818f657
  33. 31 1月, 2015 1 次提交
    • S
      Allow keyword arguments to work with ActiveJob · 31085a5c
      Sean Griffin 提交于
      Unfortunately, the HashWithIndifferent access approach is insufficient
      for our needs. It's perfectly reasonable to want to use keyword
      arguments with Active Job, which we will see as a symbol keyed hash. For
      Ruby to convert this back to keyword arguments, it must deserialize to a
      symbol keyed hash.
      
      There are two primary changes to the serialization behavior. We first
      treat a HWIA separately, and mark it as such so we can convert it back
      into a HWIA during deserialization.
      
      For normal hashes, we keep a list of all symbol keys, and convert them
      back to symbol keys after deserialization.
      
      Fixes #18741.
      31085a5c
  34. 10 1月, 2015 1 次提交
  35. 08 1月, 2015 1 次提交