nakajima-fixjour 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/fixjour/builders.rb +1 -1
- data/lib/fixjour/errors.rb +0 -4
- data/lib/fixjour/verify.rb +1 -1
- data/lib/fixjour.rb +1 -0
- metadata +1 -1
data/lib/fixjour/builders.rb
CHANGED
data/lib/fixjour/errors.rb
CHANGED
@@ -5,10 +5,6 @@ module Fixjour
|
|
5
5
|
# Raised when a builder returns an object of the wrong type
|
6
6
|
class WrongBuilderType < StandardError; end
|
7
7
|
|
8
|
-
# Raised when a builder is defined for a class that already
|
9
|
-
# has one.
|
10
|
-
class RedundantBuilder < StandardError; end
|
11
|
-
|
12
8
|
# Raised when a builder block saves the object.
|
13
9
|
class BuilderSavedRecord < StandardError; end
|
14
10
|
|
data/lib/fixjour/verify.rb
CHANGED
@@ -10,7 +10,7 @@ module Fixjour
|
|
10
10
|
result = evaluator.send("new_#{name_for(klass)}")
|
11
11
|
|
12
12
|
unless result.valid?
|
13
|
-
raise InvalidBuilder.new("The builder for #{klass} returns an invalid object")
|
13
|
+
raise InvalidBuilder.new("The builder for #{klass} returns an invalid object: #{result.errors.inspect}")
|
14
14
|
end
|
15
15
|
|
16
16
|
unless result.new_record?
|
data/lib/fixjour.rb
CHANGED