Sha256: 9aa0efd102b039c6e8dd82b69207033c704713432a40661609cb1aa876119b6f
Contents?: true
Size: 777 Bytes
Versions: 4
Compression:
Stored size: 777 Bytes
Contents
module Gherkin module Lexer class << self def [](i18n_lang) begin begin c[i18n_lang] rescue NameError, LoadError => e raise("WARNING: #{e.message}. Reverting to Ruby lexer.") unless defined?(@warned) @warned = true rb[i18n_lang] end rescue LoadError => e raise I18nLexerNotFound, "No lexer was found for #{i18n_lang} (#{e.message}). Supported languages are listed in gherkin/i18n.yml." end end def c require 'gherkin/c_lexer' CLexer end def csharp require 'gherkin/csharp_lexer' CSharpLexer end def rb require 'gherkin/rb_lexer' RbLexer end end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
gherkin-1.0.3-i386-mswin32 | lib/gherkin/lexer.rb |
gherkin-1.0.3-i386-mingw32 | lib/gherkin/lexer.rb |
gherkin-1.0.3-java | lib/gherkin/lexer.rb |
gherkin-1.0.3 | lib/gherkin/lexer.rb |