• Home
  • Testing
  • SAP
  • Web
  • Must Learn!
  • Big Data
  • Live Projects
  • Blog

Cucumber installation could be tiresome but its relatively easy.

Here is a roadmap of components that need to be installed to make Cucumber work

 

 

 

 

 

 

Cucumber Installation

PART A) Install Ruby:

Step 1) Got to http://rubyinstaller.org/downloads/

Select a package as per your OS Version

If you have 32bit version OS than click on Ruby2.0.0-p451 or have a 64bit OS then click on Ruby2.0.0-p451(x64)

Cucumber Installation

Once download is complete, start the installation. Select Your Preferred language For Installation

Cucumber Installation

Step 2) Accept license and click on next

Cucumber Installation

Step 3) Select your Installation Directory & Select all Options

Cucumber Installation

Step 4) Wait for installation to complete.

Cucumber Installation

Step 5) Once installation is complete After install ruby Lets Run Ruby!

Cucumber Installation

Step 6) You will see Ruby Command prompt same as windows cmd.

Cucumber Installation

Part B Install Ruby Development Kit

Step 1) Download Development kit here . Development kit should be same version as that of Ruby you downloaded.

Cucumber Installation

Step 2) The development kit is in .7zip format file and when you execute it ask for extract file. Just choose any directory you want extract and extract it

Cucumber Installation

Step 3) Now in extracted folder you see dk.rb file. it is development kit installation file, we need it when we install development kit in ruby.

Cucumber Installation

Step 4) Go back to Ruby cmd prompt. And locate development kit directory in cmd which you extracted for development kit.

Cucumber Installation

Step 5) Now type command "ruby (your development kit path) dk.rb init" to initialize process of development kit as shown in image.

Cucumber Installation

Step 6) Next, we have to install development kit. Type command in cmd "ruby (your development kit path)dk.rb install" for installation.

Cucumber Installation

Step 7) Devkit installation completed:

Cucumber Installation

PART C) Install Cucumber

Step 1) Type in Ruby cmd "gem install cucumber". This command will download and install Cucumber at command line itself

Cucumber Installation

After few seconds cucumber installation procedure has been start

Cucumber Installation

Step 2) To verify cucumber is installed successfully or not just type "cucumber –version"

Cucumber Installation

PART D) Install IDE

To write Cucumber Test Scripts, you need IDE

There are two popular GUI based script editor for Windows which can be used for Cucumber - .

1. Ruby mine: You can download from http://www.jetbrains.com/ruby/download/

2. Komodo edit 1.8 You can download from http://www.activestate.com/komodo-ide/downloads

I suggest as a beginner, use komodo edit as it is easy to use.

Cucumber Installation

Step 1) Open Downloaded Setup file and Click On next

Cucumber Installation

Step 2) Accept license agreement

Cucumber Installation

Step 3) Select directory for installation and click on next

Cucumber Installation

Step 4) Click on next to install

Cucumber Installation

Step 5) Installation process starts

Cucumber Installation

Step 6) Komodo install successfully

Cucumber Installation

PART E) Installation For AnsiCon:

In command prompt

  • A "Pass" Cucumber Test Case is shown in Green
  • A "Fail" Cucumber test case is shown in Red

To show colorized text in cmd prompt you have to install Ansicon tool. You can download

Installation Steps

Step 1) Download Ansicon here

Cucumber Installation

Step 2) Select a folder as per your windows OS versions

Cucumber Installation

Step - 3) Execute file ansicon

Cucumber Installation

AnsiCon installed successfully

PART F) Installation Watir

Watir is used for Web Automation in Cucumber

To install Watir , in ruby cmd type "gem install watir"

Cucumber Installation

PART G) rspec Installation

It is used to run additional libraries of cucumber for test run.

To install rspec, in ruby cmd type "gem install rspec"

Cucumber Installation

PART H) colorize Installation

It helps to colorize error syntax

To install colorize, in ruby cmd type "gem install colorize"

Cucumber Installation

Finally you are done and all set J