spec/spec_helper.rb in yard-0.8.7.4 vs spec/spec_helper.rb in yard-0.8.7.5
- old
+ new
@@ -34,9 +34,11 @@
class YARD::Parser::SourceParser
def self.parser_type; :ruby18 end
end if ENV['LEGACY']
end
+NAMED_OPTIONAL_ARGUMENTS = RUBY_VERSION >= '2.1.0'
+
def parse_file(file, thisfile = __FILE__, log_level = log.level, ext = '.rb.txt')
Registry.clear
path = File.join(File.dirname(thisfile), 'examples', file.to_s + ext)
YARD::Parser::SourceParser.parse(path, [], log_level)
end