Path to this page:
Subject: CVS commit: pkgsrc/devel/ruby-activejob70
From: Takahiro Kambe
Date: 2022-01-16 15:06:14
Message id: 20220116140614.4F879FB24@cvs.NetBSD.org
Log Message:
devel/ruby-activejob70: update to 7.0.1
7.0.1 (2021-01-06)
* Allow testing discard_on/retry_on ActiveJob::DeserializationError
Previously in perform_enqueued_jobs, deserialize_arguments_if_needed
was called before calling perform_now. When a record no longer
exists and is serialized using GlobalID this led to raising an
ActiveJob::DeserializationError before reaching perform_now call.
This behaviour makes difficult testing the job discard_on/retry_on
logic.
Now deserialize_arguments_if_needed call is postponed to when
perform_now is called.
Example:
class UpdateUserJob < ActiveJob::Base
discard_on ActiveJob::DeserializationError
def perform(user)
# ...
end
end
# In the test
User.destroy_all
assert_nothing_raised do
perform_enqueued_jobs only: UpdateUserJob
end
Jacopo Beschi
Files: