lib/docparser/output.rb in docparser-0.1.6 vs lib/docparser/output.rb in docparser-0.2.0

- old
+ new

@@ -7,11 +7,11 @@ # Creates a new output # @param filename [String] Output filename def initialize(filename: filename) @rowcount = 0 @filename = filename - raise ArgumentError, 'Please specify a filename' if filename.empty? + fail ArgumentError, 'Please specify a filename' if filename.empty? @file = open filename, 'w' classname = self.class.name.split('::').last @logger = Log4r::Logger.new("docparser::output::#{classname}") open_file end @@ -47,10 +47,10 @@ # do nothing end # Called when a row is added def write_row(row) - raise NotImplementedError.new('No row writer defined') + fail NotImplementedError, 'No row writer defined' end # Called before closing the file def footer end