diff --git a/Gemfile b/Gemfile index 50f8b79d..75c53643 100644 --- a/Gemfile +++ b/Gemfile @@ -42,10 +42,13 @@ end group :development, :test do gem 'fabrication' gem 'rspec-rails' + gem 'capybara' gem 'cucumber-rails', require: false gem "faker" gem 'pry' gem 'sqlite3' + + end group :production do @@ -53,6 +56,7 @@ group :production do end group :test do + gem "simplecov", :require => false gem "mocha" gem "database_cleaner" gem "launchy" diff --git a/README.md b/README.md index 28e42aae..fef30cc9 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ [hackety-hack.com][hh.com] is the web backend powering the collaborative features of [Hackety Hack][hh]. It is written in Rails 3 and continues to be under active development (see 'Helping Out'), the switch to Rails 3 happened quite recently so there's still lots to be done. -## Helping Out ## +###### Helping Out ### If you have any experience writing Rails apps, feel free to help out, we're open to pull requests as long as you follow a few conditions. diff --git a/features/support/env.rb b/features/support/env.rb index 07737733..a348b10b 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -3,6 +3,19 @@ # newer version of cucumber-rails. Consider adding your own code to a new file # instead of editing this one. Cucumber will automatically load all features/**/*.rb # files. +# + +require 'simplecov' +SimpleCov.start do +coverage_dir ('public/publix') + #add_filter '/features/' + add_filter '/spec/' + add_filter '/config/' + add_filter '/lib/' + add_filter '/vendor/' + #add_filter '/app/' + +end require 'cucumber/rails' diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 79d1f541..629dc4e5 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -1,7 +1,18 @@ +require 'simplecov' +SimpleCov.start do + coverage_dir('public/publix') +#add_filter '/spec/' + add_filter '/config/' + add_filter '/lib/' + add_filter '/vendor/' + add_filter '/features/' +end + ENV["RAILS_ENV"] ||= 'test' require File.expand_path("../../config/environment", __FILE__) require 'rspec/rails' require 'database_cleaner' +require 'capybara/rspec' # Requires supporting ruby files with custom matchers and macros, etc, # in spec/support/ and its subdirectories. @@ -28,4 +39,5 @@ config.before(:each) { reset_email } config.include Devise::TestHelpers, :type => :controller + config.include Capybara::DSL end