lib/inch/config/evaluation.rb in inch-0.5.6 vs lib/inch/config/evaluation.rb in inch-0.5.7
- old
+ new
@@ -21,10 +21,11 @@
def schema(constant_name, &block)
@criteria_blocks[constant_name.to_s] = Criteria.new(&block)
end
def criteria_for(constant_name)
- @criteria_blocks[constant_name.to_s]
+ @criteria_blocks[constant_name.to_s] ||
+ raise("No criteria for #{constant_name}")
end
# An Criteria describes how important certain parts of the docs are
# for the associated Object
class Criteria