Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Added spork

  • Loading branch information...
commit 20a6a98fdab51bdd7ff443e78e5c76d076dee68e 1 parent 650a8a6
@marcgg authored
View
1  Gemfile
@@ -19,6 +19,7 @@ group :test do
gem 'simplecov-rcov'
gem 'webmock'
gem 'fabrication'
+ gem 'spork'
end
group :development, :test do
View
2  Gemfile.lock
@@ -114,6 +114,7 @@ GEM
simplecov-html (0.4.5)
simplecov-rcov (0.2.3)
simplecov (>= 0.4.1)
+ spork (0.8.5)
sqlite3 (1.3.3)
thor (0.14.6)
timecop (0.3.5)
@@ -144,6 +145,7 @@ DEPENDENCIES
rspec-rails
simplecov
simplecov-rcov
+ spork
sqlite3 (= 1.3.3)
timecop
webmock
View
10 README.md
@@ -99,6 +99,16 @@ Any pull request needs to have its set of tests to be accepted (except
for themes). I know right, do what I say and not what I do... It'll get
fixed, tests are coming, I promise.
+### Spork
+
+You can use spork to run the test suite:
+
+ bundle exec spork
+
+... to start the drb server and then:
+
+ bundle exec rspec spec --drb
+
## Compatibility
ffocused runs on Ruby 1.9.2 and 1.8.7, but the support for 1.8.7 will be
soon dropped.
View
7 app/views/layouts/home.html.haml
@@ -6,11 +6,6 @@
= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js", "jquery.scrollTo-1.4.2-min.js", "home.js"
%body
- #warning{:style => "color:red; border-bottom: 1px solid red; line-height: 18px; font-size: 1.4em; text-align: center; padding: 15px;"}
- Warning, this is a beta version of the beta website. It's very meta, I know.
- %br
- Most features won't be working and this page is only for testing purposes and getting feedbacks.
-
%header
.container
#top-action
@@ -40,7 +35,7 @@
= link_to "- Facebook", "http://facebook.com"
= link_to "- Instagram", "http://instagr.am"
.footer-item
- %h3 Find Us
+ %h3 Find and Contact Us
= link_to "- on Twitter to get updates", "http://twitter.com/ffocusedapp"
= link_to "- on Github to see the code & help out", "http://github.com/marcgg/ffocused"
View
40 spec/spec_helper.rb
@@ -1,24 +1,34 @@
-require 'simplecov'
-SimpleCov.start 'rails'
+require 'rubygems'
+require 'spork'
-ENV["RAILS_ENV"] ||= 'test'
-require File.expand_path("../../config/environment", __FILE__)
-require 'rspec/rails'
+Spork.prefork do
+ require 'simplecov'
-Dir[Rails.root.join("spec/support/**/*.rb")].each {|f| require f}
+ SimpleCov.start 'rails'
-WebMock.disable_net_connect!
+ ENV["RAILS_ENV"] ||= 'test'
+ require File.expand_path("../../config/environment", __FILE__)
+ require 'rspec/rails'
-RSpec.configure do |config|
- config.mock_with :rr
+ Dir[Rails.root.join("spec/support/**/*.rb")].each {|f| require f}
- config.before :each do
- DatabaseCleaner.strategy = :truncation
- DatabaseCleaner.start
- end
+ WebMock.disable_net_connect!
+
+ RSpec.configure do |config|
+ config.mock_with :rr
+
+ config.before :each do
+ DatabaseCleaner.strategy = :truncation
+ DatabaseCleaner.start
+ end
- config.after do
- DatabaseCleaner.clean
+ config.after do
+ DatabaseCleaner.clean
+ end
end
end
+Spork.each_run do
+end
+
+
Please sign in to comment.
Something went wrong with that request. Please try again.