Skip to content

Commit

Permalink
Adds simpleCov and the first test
Browse files Browse the repository at this point in the history
  • Loading branch information
Eduardo Figarola committed Mar 18, 2014
1 parent c2203c5 commit 229e30d
Show file tree
Hide file tree
Showing 7 changed files with 31 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,9 @@
/tmp
.env
/config/database.yml

# Ignore coverage folder
/coverage

# Ignore other files
.ruby-version
1 change: 1 addition & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,6 @@ group :development, :test do
gem 'pry'
gem 'rspec-rails'
gem 'shoulda-matchers'
gem 'simplecov', '~> 0.7.1', require: false
end

5 changes: 5 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,10 @@ GEM
sprockets-rails (~> 2.0.0)
shoulda-matchers (2.5.0)
activesupport (>= 3.0.0)
simplecov (0.7.1)
multi_json (~> 1.0)
simplecov-html (~> 0.7.1)
simplecov-html (0.7.1)
slop (3.5.0)
sprockets (2.11.0)
hike (~> 1.2)
Expand Down Expand Up @@ -219,4 +223,5 @@ DEPENDENCIES
rspec-rails
sass-rails (~> 4.0.0)
shoulda-matchers
simplecov (~> 0.7.1)
uglifier (>= 1.3.0)
4 changes: 4 additions & 0 deletions app/assets/stylesheets/dashboard/diffs.css.sass
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#diff-code
display: inline-block
white-space: inherit

1 change: 1 addition & 0 deletions app/assets/stylesheets/dashboard/index.css.sass
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,5 @@
text-decoration: underline

@import 'media_queries'
@import 'diffs'

12 changes: 12 additions & 0 deletions spec/controllers/welcome_controller_spec.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
require 'spec_helper'

describe WelcomeController do
describe '#index' do

it 'should render index' do
get :index
expect(response.status).to eql 200
end
end
end

2 changes: 2 additions & 0 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
require 'simplecov'
SimpleCov.start 'rails'
# This file is copied to spec/ when you run 'rails generate rspec:install'
ENV["RAILS_ENV"] ||= 'test'
require File.expand_path("../../config/environment", __FILE__)
Expand Down

0 comments on commit 229e30d

Please sign in to comment.