aanand/deadweight — pull request #22 by jmuheim (2014-01-05 21:31:08+00:00)
Title: Rails 4 support

I never used this gem before, but I guess that it's not working anymore for newer versions of Rack and/or Rails, see especially my changes in `lib/deadweight/rack/capturing_middleware.rb` (`respond_to :body` doesn't seem to be correct anymore) and in `lib/deadweight/hijack/rails.rb ` (`application.css` is no longer under `stylesheets`, but in `assets`).

I didn't find a more elegant way to load `application.css` into `DeadWeight` than to do a manual `rake assets:precompile` from within Ruby. It would be nice to use the same source that Rails generates when a `js: true` test is run, but this is done only the first time such a request test is run, so we don't have it at this early stage. Maybe there is a way to trigger the generation manually somehow?

I also refactored the console output: I don't think it's useful to hijack the log and send it to a file. I want to see what's happening with my tests, e.g. how many % already are done, etc.

**As I only use this as a Rails gem, I didn't verify that all other functionality's still working.**