Skip to content

Instantly share code, notes, and snippets.

View jacobsimeon's full-sized avatar

Jacob Morris jacobsimeon

  • Mozilla/Pocket
  • Vancouver, WA
View GitHub Profile
diff --git a/activesupport/lib/active_support/callbacks.rb b/activesupport/lib/active_support/callbacks.rb
index e948314..a24b35a 100644
--- a/activesupport/lib/active_support/callbacks.rb
+++ b/activesupport/lib/active_support/callbacks.rb
@@ -321,7 +321,13 @@ module ActiveSupport
_normalize_legacy_filter(kind, filter)
scopes = Array(chain.config[:scope])
- method_to_call = scopes.map{ |s| s.is_a?(Symbol) ? send(s) : s }.join("_")
+ method_to_call = scopes.map { |s|
@sr75
sr75 / testing-subdomains-cucumber-capybara.md
Created January 6, 2013 07:09
Express guide to a rails 3.2+ testing custom subdomains using cucumber capybara with pow setup... along with devise mailer config helper (only useful when needing to test custom subdomains in your rails app).

Express guide to a rails 3.2+ testing custom app subdomains using cucumber capybara with a pow setup... along with devise mailer config helper example (useful if you need to test various auth situations for custom subdomains in a rails app).

If you haven't used pow, I wouldn't recommend it for local web dev... there's much better gems for local web dev like unicorn-rails or passenger nginx standalone are far better choices IMHO. I use pow for all the local name redirects to a port like explained below, with a rails dev server listening on that port running unicorn-rails.

So we're going to use it for the awesome subdomain redirect to a local customapp.dev on a specific port magic mojo.

First install pow.cx

  • now go to pow.cx and install
  • cd ~/.pow