title: Rails 4: How to reset test database?
body: <p>I'm on Rails 4 and have noticed some of my RSpec tests are failing because some of my test refactorings use a before filter (presumably because of transactions). This post describes a similar issue:</p>
  <p><a href="https://stackoverflow.com/questions/16268728/rails-test-database-not-clearing-after-some-runs">rails test database not clearing after some runs</a></p>
  <p>In lieu of using the DatabaseCleaner gem, is there a rake command to clear out the test database?  I believe <code>rake db:test:prepare</code> is deprecated in Rails 4. Also, if before transactions like</p>
  <pre><code>`post :create, user: Fabricate.attributes_for(:user)`
  </code></pre>
  <p>are persistent, is there an alternative way of refactoring to avoid the need to manually clear out the test database?</p>