Skip to content

Commit

Permalink
Automatic tests with guard and formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
lfzawacki committed Apr 17, 2015
1 parent 9369d8a commit fc401c3
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 4 deletions.
6 changes: 4 additions & 2 deletions Gemfile
Expand Up @@ -50,10 +50,12 @@ group :development, :test do

gem 'minitest-reporters'

gem 'guard'
gem 'guard-minitest'
gem 'minitest-rails-capybara'

gem 'ffi'

gem 'guard'
gem 'guard-minitest'
end


Expand Down
23 changes: 23 additions & 0 deletions Gemfile.lock
Expand Up @@ -82,6 +82,12 @@ GEM
builder (3.2.2)
byebug (4.0.4)
columnize (= 0.9.0)
capybara (2.4.4)
mime-types (>= 1.16)
nokogiri (>= 1.3.3)
rack (>= 1.0.0)
rack-test (>= 0.5.4)
xpath (~> 2.0)
carrierwave (0.10.0)
activemodel (>= 3.2.0)
activesupport (>= 3.2.0)
Expand Down Expand Up @@ -178,6 +184,20 @@ GEM
mime-types (2.4.3)
mini_portile (0.6.2)
minitest (5.5.1)
minitest-capybara (0.7.1)
capybara (~> 2.2)
minitest (~> 5.0)
rake
minitest-metadata (0.5.3)
minitest (>= 4.7, < 6.0)
minitest-rails (2.1.1)
minitest (~> 5.4)
railties (~> 4.1)
minitest-rails-capybara (2.1.1)
capybara (~> 2.0)
minitest-capybara (~> 0.7.0)
minitest-metadata (~> 0.5.0)
minitest-rails (~> 2.1)
minitest-reporters (1.0.11)
ansi
builder
Expand Down Expand Up @@ -290,6 +310,8 @@ GEM
binding_of_caller (>= 0.7.2)
railties (>= 4.0)
sprockets-rails (>= 2.0, < 4.0)
xpath (2.0.0)
nokogiri (~> 1.3)

PLATFORMS
ruby
Expand All @@ -310,6 +332,7 @@ DEPENDENCIES
haml-rails (~> 0.9)
jbuilder (~> 2.0)
jquery-rails
minitest-rails-capybara
minitest-reporters
pg
quiet_assets
Expand Down
1 change: 1 addition & 0 deletions Guardfile
Expand Up @@ -26,6 +26,7 @@
guard :minitest do
# with Minitest::Unit
watch(%r{^test/(.*)\/?test_(.*)\.rb$})
watch(%r{^test/(.*)\/?(.*)_test\.rb$})
watch(%r{^lib/(.*/)?([^/]+)\.rb$}) { |m| "test/#{m[1]}test_#{m[2]}.rb" }
watch(%r{^test/test_helper\.rb$}) { 'test' }

Expand Down
6 changes: 4 additions & 2 deletions test/test_helper.rb
Expand Up @@ -2,9 +2,11 @@
require File.expand_path('../../config/environment', __FILE__)
require 'rails/test_help'
require 'minitest/reporters'
require 'minitest/rails/capybara'
require 'html_reporter'

reporter_options = { color: true, slow_count: 5 }
Minitest::Reporters.use! [Minitest::Reporters::DefaultReporter.new(reporter_options)]
reporter_options = { color: true }
Minitest::Reporters.use! [Minitest::Reporters::HtmlReporter.new]

class ActiveSupport::TestCase
# Setup all fixtures in test/fixtures/*.yml for all tests in alphabetical order.
Expand Down

0 comments on commit fc401c3

Please sign in to comment.