apps/blueprint/models/epic.rb in brief-1.17.3 vs apps/blueprint/models/epic.rb in brief-1.17.4

- old
+ new

@@ -95,11 +95,11 @@ def generate_feature(feature_heading) path = feature_file_for(feature_heading) FileUtils.mkdir_p(path.dirname) - c = generate_feature_content(c) + c = generate_feature_content(feature_heading) path.open("w+") do |fh| fh.write(c) end end @@ -180,10 +180,12 @@ def validation_report warnings = [] errors = [] begin - features + if features.any? {|f| f.title.to_s.length == 0 } + errors.push "Feature is missing title. Should be an h2 element" + end rescue => e errors.push "Error generating features: #{ e.message }" end if title.to_s.length == 0