Class: DatabaseCleaner::ActiveRecord::Surgicalstrike

Inherits:
Object
  • Object
show all
Includes:
Base, Generic::Dataholder, Generic::Surgicalstrike
Defined in:
lib/database_cleaner/active_record/surgicalstrike.rb

Instance Attribute Summary

Attributes included from Base

#connection_hash

Instance Method Summary collapse

Methods included from Generic::Surgicalstrike

#initialize

Methods included from Generic::Dataholder

#checktarget

Methods included from Base

#connection_klass, #create_connection_klass, #db, #db=, #load_config

Methods included from Generic::Base

#db, included

Instance Method Details

#cleanObject



43
44
45
# File 'lib/database_cleaner/active_record/surgicalstrike.rb', line 43

def clean
  strike_tables
end

#startObject



36
37
38
39
40
41
# File 'lib/database_cleaner/active_record/surgicalstrike.rb', line 36

def start
  connection = connection_klass.connection

  $strike_targets = tables_to_strike(connection)
  $vips = Array.new
end