Reworked engines to use a dummy app.

This is needed if you want to start using this pattern in a large rails
app and want to ensure that the engines do not depend on the rails app.

Adds a bit of duplication that can be removed.