Skip to content

Instantly share code, notes, and snippets.

@viddo
Created October 22, 2013 17:00
Show Gist options
  • Save viddo/7104245 to your computer and use it in GitHub Desktop.
Save viddo/7104245 to your computer and use it in GitHub Desktop.
Gist to troubleshoot https://github.com/modeset/teaspoon/issues/120#issuecomment-26818114 Patch to be applied on a fresh Rails 4 project. teaspoon gem is pointing to a local checkout of the repo at rev https://github.com/modeset/teaspoon/tree/b5baaf387f87537bda64f2894563ab2d7ef9807b
diff --git a/Gemfile b/Gemfile
index 30d54d4..5461168 100644
--- a/Gemfile
+++ b/Gemfile
@@ -43,3 +43,13 @@ end
# Use debugger
# gem 'debugger', group: [:development, :test]
+
+# Get some nice better errors on development
+group :development do
+ gem 'better_errors'
+end
+
+group :development, :test do
+ gem "teaspoon", path: '~/src/teaspoon'
+end
+
diff --git a/Gemfile.lock b/Gemfile.lock
index 7cab85a..221bf43 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,3 +1,10 @@
+PATH
+ remote: ~/src/teaspoon
+ specs:
+ teaspoon (0.7.7)
+ phantomjs (>= 1.8.1.1)
+ railties (>= 3.2.5, < 5)
+
GEM
remote: https://rubygems.org/
specs:
@@ -27,7 +34,18 @@ GEM
tzinfo (~> 0.3.37)
arel (4.0.0)
atomic (1.1.14)
+ better_errors (1.0.1)
+ coderay (>= 1.0.0)
+ erubis (>= 2.6.6)
builder (3.1.4)
+ capybara (2.1.0)
+ mime-types (>= 1.16)
+ nokogiri (>= 1.3.3)
+ rack (>= 1.0.0)
+ rack-test (>= 0.5.4)
+ xpath (~> 2.0)
+ cliver (0.2.2)
+ coderay (1.0.9)
coffee-rails (4.0.1)
coffee-script (>= 2.2.0)
railties (>= 4.0.0, < 5.0)
@@ -50,8 +68,18 @@ GEM
mime-types (~> 1.16)
treetop (~> 1.4.8)
mime-types (1.25)
+ mini_portile (0.5.1)
minitest (4.7.5)
multi_json (1.8.2)
+ nokogiri (1.6.0)
+ mini_portile (~> 0.5.0)
+ phantomjs (1.8.1.1)
+ poltergeist
+ poltergeist (1.4.1)
+ capybara (~> 2.1.0)
+ cliver (~> 0.2.1)
+ multi_json (~> 1.0)
+ websocket-driver (>= 0.2.0)
polyglot (0.3.3)
rack (1.5.2)
rack-test (0.6.2)
@@ -103,11 +131,15 @@ GEM
uglifier (2.2.1)
execjs (>= 0.3.0)
multi_json (~> 1.0, >= 1.0.2)
+ websocket-driver (0.3.0)
+ xpath (2.0.0)
+ nokogiri (~> 1.3)
PLATFORMS
ruby
DEPENDENCIES
+ better_errors
coffee-rails (~> 4.0.0)
jbuilder (~> 1.2)
jquery-rails
@@ -115,5 +147,6 @@ DEPENDENCIES
sass-rails (~> 4.0.0)
sdoc
sqlite3
+ teaspoon!
turbolinks
uglifier (>= 1.3.0)
diff --git a/app/assets/javascripts/application.js b/app/assets/javascripts/application.js
index d6925fa..5f461e2 100644
--- a/app/assets/javascripts/application.js
+++ b/app/assets/javascripts/application.js
@@ -1,16 +1 @@
-// This is a manifest file that'll be compiled into application.js, which will include all the files
-// listed below.
-//
-// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
-// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
-//
-// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
-// compiled file.
-//
-// Read Sprockets README (https://github.com/sstephenson/sprockets#sprockets-directives) for details
-// about supported directives.
-//
-//= require jquery
-//= require jquery_ujs
-//= require turbolinks
-//= require_tree .
+//= require non_extisting_file
diff --git a/config/environments/development.rb b/config/environments/development.rb
index d6f87b5..771e757 100644
--- a/config/environments/development.rb
+++ b/config/environments/development.rb
@@ -7,7 +7,7 @@ TeaspoonErr::Application.configure do
config.cache_classes = false
# Do not eager load code on boot.
- config.eager_load = false
+ config.eager_load = true
# Show full error reports and disable caching.
config.consider_all_requests_local = true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment