Class: ActiveRecordAnonymizer::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/active_record_anonymizer/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



7
8
9
10
11
12
# File 'lib/active_record_anonymizer/configuration.rb', line 7

def initialize
  @environments = %i[development]
  @skip_update = false
  @alias_original_columns = false
  @alias_column_name = "original"
end

Instance Attribute Details

#alias_column_nameObject

Returns the value of attribute alias_column_name.



5
6
7
# File 'lib/active_record_anonymizer/configuration.rb', line 5

def alias_column_name
  @alias_column_name
end

#alias_original_columnsObject

Returns the value of attribute alias_original_columns.



5
6
7
# File 'lib/active_record_anonymizer/configuration.rb', line 5

def alias_original_columns
  @alias_original_columns
end

#environmentsObject

Returns the value of attribute environments.



5
6
7
# File 'lib/active_record_anonymizer/configuration.rb', line 5

def environments
  @environments
end

#skip_updateObject

Returns the value of attribute skip_update.



5
6
7
# File 'lib/active_record_anonymizer/configuration.rb', line 5

def skip_update
  @skip_update
end

Instance Method Details

#resetObject

Reset all configuration options to defaults. Required for tests to maintain isolation between test cases.



16
17
18
# File 'lib/active_record_anonymizer/configuration.rb', line 16

def reset
  initialize
end