Module: Vault::Test::DB::Truncation
- Defined in:
- lib/vault-test-tools/db_helpers.rb
Instance Method Summary collapse
Instance Method Details
#teardown ⇒ Object
4 5 6 7 |
# File 'lib/vault-test-tools/db_helpers.rb', line 4 def teardown super truncate_tables! end |
#truncate_tables! ⇒ Object
9 10 11 12 13 |
# File 'lib/vault-test-tools/db_helpers.rb', line 9 def truncate_tables! (db.tables - [:schema_migrations]).each do |table| db << "truncate #{table}" end end |