One of the famous “problems” when you get Cucumber running, is to have a gherkin error.
Digged a lot for a solution, and found that the matter comes from a precompiled package of gherkin.
BAsed on the facts, to be able to have a working cucumber framework, you should have devkit and force a clean install ( with compiling ) of the gherkin.
Remember to use proper devkit for your ruby version.
ATM, been playing with ruby 2.1 and devkit mingw64-32 biti.
Commands to have gherkin working , if you get errors when trying cucumber ( after bundle install, of course! )
gem uninstall gherkin --force
( should see something like
Successfully uninstalled gherkin-2.12.2
Successfully uninstalled gherkin-2.12.2-x86-mingw32
gem install gherkin --platform ruby ( -- platform is mandatory! )
Fetching: gherkin-2.12.2.gem (100%)
Temporarily enhancing PATH to include DevKit…
Building native extensions. This could take a while…
That ( and shoulda wait for some ) would make your gherkin lexer work properly.
That should help you get rid of the
C:/Ruby21/lib/ruby/2.1.0/i386-mingw32. Reverting to Ruby lexer.
WARNING: cannot load such file -- 2.1/gherkin_lexer_en
Couldn't load 2.1/gherkin_lexer_en
The $LOAD_PATH was:
The troubling messages:
No lexer was found for en (cannot load such file — gherkin/lexer/en). Supported languages are listed in gherkin/i18n.js
C:/Ruby21/lib/ruby/gems/2.1.0/gems/gherkin-2.12.2-x86-mingw32/lib/gherkin/i18n.rb:108:in `rescue in lexer’