Class: Minitest::Set::Change
- Inherits:
-
Object
- Object
- Minitest::Set::Change
- Defined in:
- lib/minitest/set/change.rb
Instance Method Summary collapse
-
#initialize(object, **attributes) ⇒ Change
constructor
A new instance of Change.
- #setup ⇒ Object
- #teardown ⇒ Object
Constructor Details
#initialize(object, **attributes) ⇒ Change
Returns a new instance of Change.
2 3 4 |
# File 'lib/minitest/set/change.rb', line 2 def initialize(object, **attributes) @object, @attributes = object, attributes end |
Instance Method Details
#setup ⇒ Object
6 7 8 9 |
# File 'lib/minitest/set/change.rb', line 6 def setup @previous_attributes = extract_previous_attributes set attributes end |
#teardown ⇒ Object
11 12 13 |
# File 'lib/minitest/set/change.rb', line 11 def teardown set previous_attributes end |