From 3faa61ede58aa29400e4e062a799c61913ae213f Mon Sep 17 00:00:00 2001 From: Cristian Bica Date: Sun, 17 Aug 2014 23:48:44 +0300 Subject: [ActiveJob] raise DeserializationError when got an error deserializing --- activejob/test/models/person.rb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'activejob/test/models/person.rb') diff --git a/activejob/test/models/person.rb b/activejob/test/models/person.rb index b31396db4b..76a8f40616 100644 --- a/activejob/test/models/person.rb +++ b/activejob/test/models/person.rb @@ -1,9 +1,12 @@ class Person + class RecordNotFound < StandardError; end + include GlobalID::Identification attr_reader :id def self.find(id) + raise RecordNotFound.new("Cannot find person with ID=404") if id.to_i==404 new(id) end -- cgit v1.2.3