summaryrefslogtreecommitdiff
path: root/spec/ruby/core/data/constants_spec.rb
blob: 2eb43d501e6d9b8d426466801afe31fca25366c6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
require_relative '../../spec_helper'

ruby_version_is ''...'3.2' do
  describe "Data" do
    it "does not exist anymore" do
      Object.should_not have_constant(:Data)
    end
  end
end

ruby_version_is '3.2' do
  describe "Data" do
    it "is a new constant" do
      Data.superclass.should == Object
    end

    it "is not deprecated" do
      -> { Data }.should_not complain
    end
  end
end