aboutsummaryrefslogtreecommitdiffstats
path: root/spec/spec_helper.rb
diff options
context:
space:
mode:
authorSeb Bacon <seb.bacon@gmail.com>2012-07-13 11:19:54 +0100
committerSeb Bacon <seb.bacon@gmail.com>2012-07-13 11:19:54 +0100
commit67df820b1d41402a413d1899cfdbdb4da69f7685 (patch)
treee81bff73aec870ba03bea0218d77c7e54a703c82 /spec/spec_helper.rb
parent39fdae7de23244b47581c197e1d78506aebf5af1 (diff)
parent2257aad346959a843b58c61758b5daf4a58688da (diff)
Merge branch 'feature/czech-website-support' into develop
Diffstat (limited to 'spec/spec_helper.rb')
-rw-r--r--spec/spec_helper.rb13
1 files changed, 13 insertions, 0 deletions
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index a7f3020c1..c11c7c5bc 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -206,3 +206,16 @@ def load_test_categories
"Miscellaneous",
[ "other", "Miscellaneous", "miscellaneous" ],])
end
+
+
+# Monkeypatch applicationcontroller because the `render_to_string`
+# method in the original breaks all the rspec test assertions such as
+# `should render_template('foo')`. Same problem as
+# http://stackoverflow.com/questions/8174415/is-it-possible-to-assert-template-or-render-template-against-the-same-partial-wi
+# - a bug in either Rails or Rspec I don't have the time to fix :(
+
+class ApplicationController < ActionController::Base
+ def set_popup_banner
+ @popup_banner = nil
+ end
+end