diff options
author | Benoit Daloze <eregontp@gmail.com> | 2023-06-26 15:55:11 +0200 |
---|---|---|
committer | Benoit Daloze <eregontp@gmail.com> | 2023-06-26 15:55:11 +0200 |
commit | 515bd4214497b3af02f6eef51b496ad9a0cf6b3b (patch) | |
tree | 4554360d275a3bb9dc696f952b8f3d1bcd88f18a /spec/ruby/core/main | |
parent | f73fa299279ac322bd921691d1ba0e8bf2b39b5f (diff) |
Update to ruby/spec@30e1c35
Diffstat (limited to 'spec/ruby/core/main')
-rw-r--r-- | spec/ruby/core/main/private_spec.rb | 12 | ||||
-rw-r--r-- | spec/ruby/core/main/public_spec.rb | 12 |
2 files changed, 10 insertions, 14 deletions
diff --git a/spec/ruby/core/main/private_spec.rb b/spec/ruby/core/main/private_spec.rb index cac0645b40..e8c1f3f44c 100644 --- a/spec/ruby/core/main/private_spec.rb +++ b/spec/ruby/core/main/private_spec.rb @@ -22,13 +22,11 @@ describe "main#private" do end end - ruby_version_is "3.0" do - context "when single argument is passed and is an array" do - it "sets the visibility of the given methods to private" do - eval "private [:main_public_method, :main_public_method2]", TOPLEVEL_BINDING - Object.should have_private_method(:main_public_method) - Object.should have_private_method(:main_public_method2) - end + context "when single argument is passed and is an array" do + it "sets the visibility of the given methods to private" do + eval "private [:main_public_method, :main_public_method2]", TOPLEVEL_BINDING + Object.should have_private_method(:main_public_method) + Object.should have_private_method(:main_public_method2) end end diff --git a/spec/ruby/core/main/public_spec.rb b/spec/ruby/core/main/public_spec.rb index 91f045dbab..31baad4583 100644 --- a/spec/ruby/core/main/public_spec.rb +++ b/spec/ruby/core/main/public_spec.rb @@ -22,13 +22,11 @@ describe "main#public" do end end - ruby_version_is "3.0" do - context "when single argument is passed and is an array" do - it "sets the visibility of the given methods to public" do - eval "public [:main_private_method, :main_private_method2]", TOPLEVEL_BINDING - Object.should_not have_private_method(:main_private_method) - Object.should_not have_private_method(:main_private_method2) - end + context "when single argument is passed and is an array" do + it "sets the visibility of the given methods to public" do + eval "public [:main_private_method, :main_private_method2]", TOPLEVEL_BINDING + Object.should_not have_private_method(:main_private_method) + Object.should_not have_private_method(:main_private_method2) end end |