From 2f5816eb08ee0bd1ebda99ef2e4eca6702ca3a9c Mon Sep 17 00:00:00 2001 From: Tim Felgentreff Date: Thu, 16 Jun 2011 10:31:20 +0200 Subject: [PATCH] explicitely use public_method_defined instead of just method_defined --- test/settings_test.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/settings_test.rb b/test/settings_test.rb index 2bf866e3..4654f1ac 100644 --- a/test/settings_test.rb +++ b/test/settings_test.rb @@ -390,9 +390,9 @@ class SettingsTest < Test::Unit::TestCase it 'is possible to use Module#public' do @base.send(:define_method, :foo) { } @base.send(:private, :foo) - assert !@base.method_defined?(:foo) + assert !@base.public_method_defined?(:foo) @base.send(:public, :foo) - assert @base.method_defined?(:foo) + assert @base.public_method_defined?(:foo) end it 'is possible to use the keyword public in a sinatra app' do @@ -402,8 +402,8 @@ class SettingsTest < Test::Unit::TestCase public def pub; end end - assert !app.method_defined?(:priv) - assert app.method_defined?(:pub) + assert !app.public_method_defined?(:priv) + assert app.public_method_defined?(:pub) end end