diff options
author | Daniel Colson <danieljamescolson@gmail.com> | 2018-01-24 21:14:10 -0500 |
---|---|---|
committer | Daniel Colson <danieljamescolson@gmail.com> | 2018-01-25 23:32:58 -0500 |
commit | 0d50cae996c51630361e8514e1f168b0c48957e1 (patch) | |
tree | dfbf9609ff6f3d859e584874ac6d8bdc91304c08 /activemodel/test/cases/callbacks_test.rb | |
parent | 8baca31dbe522cb407f0b3b8c8d3d4a6804e5aed (diff) | |
download | rails-0d50cae996c51630361e8514e1f168b0c48957e1.tar.gz rails-0d50cae996c51630361e8514e1f168b0c48957e1.tar.bz2 rails-0d50cae996c51630361e8514e1f168b0c48957e1.zip |
Use respond_to test helpers
Diffstat (limited to 'activemodel/test/cases/callbacks_test.rb')
-rw-r--r-- | activemodel/test/cases/callbacks_test.rb | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/activemodel/test/cases/callbacks_test.rb b/activemodel/test/cases/callbacks_test.rb index a5d29d0f22..1ec12d8222 100644 --- a/activemodel/test/cases/callbacks_test.rb +++ b/activemodel/test/cases/callbacks_test.rb @@ -85,21 +85,21 @@ class CallbacksTest < ActiveModel::TestCase end test "only selects which types of callbacks should be created" do - assert !ModelCallbacks.respond_to?(:before_initialize) - assert !ModelCallbacks.respond_to?(:around_initialize) + assert_not_respond_to ModelCallbacks, :before_initialize + assert_not_respond_to ModelCallbacks, :around_initialize assert_respond_to ModelCallbacks, :after_initialize end test "only selects which types of callbacks should be created from an array list" do assert_respond_to ModelCallbacks, :before_multiple assert_respond_to ModelCallbacks, :around_multiple - assert !ModelCallbacks.respond_to?(:after_multiple) + assert_not_respond_to ModelCallbacks, :after_multiple end test "no callbacks should be created" do - assert !ModelCallbacks.respond_to?(:before_empty) - assert !ModelCallbacks.respond_to?(:around_empty) - assert !ModelCallbacks.respond_to?(:after_empty) + assert_not_respond_to ModelCallbacks, :before_empty + assert_not_respond_to ModelCallbacks, :around_empty + assert_not_respond_to ModelCallbacks, :after_empty end class Violin |