lib/teaspoon/runner.rb in teaspoon-0.7.4 vs lib/teaspoon/runner.rb in teaspoon-0.7.5
- old
+ new
@@ -34,10 +34,10 @@
Teaspoon::Formatters.const_get("#{formatter.to_s.camelize}Formatter")
end
def output_from(line)
json = JSON.parse(line)
- return false unless json["_teaspoon"] && json["type"]
+ return false unless json && json["_teaspoon"] && json["type"]
result = Teaspoon::Result.build_from_json(json)
notify_formatters result
@failure_count += 1 if result.failing?
return true
rescue JSON::ParserError