class CallbacksTest::ExcludingDuplicatesCallbackTest

Public Instance Methods

test_excludes_duplicates_in_one_call() click to toggle source
# File activesupport/test/callbacks_test.rb, line 932
def test_excludes_duplicates_in_one_call
  model = DuplicatingCallbacksInSameCall.new
  model.save
  assert_equal ["two", "one", "three", "yielded"], model.record
end
test_excludes_duplicates_in_separate_calls() click to toggle source
# File activesupport/test/callbacks_test.rb, line 926
def test_excludes_duplicates_in_separate_calls
  model = DuplicatingCallbacks.new
  model.save
  assert_equal ["two", "one", "three", "yielded"], model.record
end