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

exp is String, so it's always truthy

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67395 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
kazu 2019-03-31 15:37:45 +00:00
parent 4e0420f577
commit 5e86970840

View file

@ -968,7 +968,7 @@ class TestRubyOptions < Test::Unit::TestCase
[["disable", "false"], ["enable", "true"]].each do |opt, exp|
%W[frozen_string_literal frozen-string-literal].each do |arg|
key = "#{opt}=#{arg}"
negopt = exp ? "disable" : "enable"
negopt = exp == "true" ? "disable" : "enable"
env = {"RUBYOPT"=>"--#{negopt}=#{arg}"}
a.for(key) do
assert_in_out_err([env, "--disable=gems", "--#{key}"], 'p("foo".frozen?)', [exp])