diff options
| author | Benoit Daloze <eregontp@gmail.com> | 2026-01-28 22:30:21 +0100 |
|---|---|---|
| committer | Benoit Daloze <eregontp@gmail.com> | 2026-01-28 23:01:22 +0100 |
| commit | dbd2ff7adca9b49e4bfa7bc3ec8b83bd437f8cb7 (patch) | |
| tree | 5f4f1609d2015fde92c25b175b84078dfcf1c92f /spec/ruby/core/struct | |
| parent | a8b877a843643fbdccd1a42efaf94ad27705dd55 (diff) | |
Update to ruby/spec@83e26c9
Diffstat (limited to 'spec/ruby/core/struct')
| -rw-r--r-- | spec/ruby/core/struct/new_spec.rb | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/spec/ruby/core/struct/new_spec.rb b/spec/ruby/core/struct/new_spec.rb index 1d35de7b87..741d6889af 100644 --- a/spec/ruby/core/struct/new_spec.rb +++ b/spec/ruby/core/struct/new_spec.rb @@ -77,18 +77,10 @@ describe "Struct.new" do -> { Struct.new(:animal, { name: 'chris' }) }.should raise_error(TypeError) end - ruby_version_is ""..."3.3" do - it "raises ArgumentError if not provided any arguments" do - -> { Struct.new }.should raise_error(ArgumentError) - end - end - - ruby_version_is "3.3" do - it "works when not provided any arguments" do - c = Struct.new - c.should be_kind_of(Class) - c.superclass.should == Struct - end + it "works when not provided any arguments" do + c = Struct.new + c.should be_kind_of(Class) + c.superclass.should == Struct end it "raises ArgumentError when there is a duplicate member" do |
