1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/spec/ruby/core/env/index_spec.rb

13 lines
278 B
Ruby
Raw Normal View History

require_relative '../../spec_helper'
require_relative 'shared/key'
2020-09-30 07:43:19 -04:00
describe "ENV.index" do
it_behaves_like :env_key, :index
2019-11-30 15:26:52 -05:00
2020-09-30 07:43:19 -04:00
it "warns about deprecation" do
-> do
ENV.index("foo")
end.should complain(/warning: ENV.index is deprecated; use ENV.key/)
2019-11-30 15:26:52 -05:00
end
end