Giter Club home page Giter Club logo

cucumber-sinatra's Introduction

cucumber-sinatra

Description

This little gem will help you to initialize a cucumber environment for a sinatra application. It will generate the required files from templates.

For now it's generating an env.rb that is using rspec and capybara. More options might be added later.

Installation

It's available as a gem that can be installed with the following command.

    gem install cucumber-sinatra

To use the generated templates without any modification, you'll have to install the rspec (v2) and capybara (at least v1.0.0) gems as well.

Usage

To initialize the cucumber environment, just execute cucumber-sinatra like this:

    # cucumber-sinatra init MyApp lib/my_app.rb
         [ADDED]  features/support/env.rb
         [ADDED]  features/support/paths.rb
         [ADDED]  features/step_definitions/web_steps.rb
    #
  • The first argument is the class name of your application.
  • The second argument is the path to the application file that should be required.

Using the --app option with init will also generate the given application file and a working config.ru.

    # cucumber-sinatra init --app MyApp lib/my_app.rb
         [ADDED]  features/support/env.rb
         [ADDED]  features/support/paths.rb
         [ADDED]  features/step_definitions/web_steps.rb
         [ADDED]  lib/my_app.rb
         [ADDED]  config.ru
    #

Copyright

The content of the following files has been taken from the cucumber-rails project which is licensed under the MIT license.

  • lib/cucumber/sinatra/templates/features/step_definitions/web_steps.rbt
  • lib/cucumber/sinatra/templates/features/support/paths.rbt

The rest is licensed under a BSD license.

See the LICENSE file for a copy of both licenses.

cucumber-sinatra's People

Contributors

bernd avatar heroiceric avatar johana-star avatar rebelwarrior avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.