Project

General

Profile

Misc #11770 » 0001-Add-test-cases-for-KCODE-and-warning.patch

yui-knk (Kaneko Yuichiro), 12/05/2015 01:09 PM

View differences:

test/ruby/test_regexp.rb
537 537
    assert_nothing_raised { $= = nil }
538 538
  end
539 539

  
540
  def test_KCODE_warning
541
    assert_warning(/variable \$KCODE is no longer effective; ignored/) { $KCODE = nil }
542
    assert_warning(/variable \$KCODE is no longer effective/) { $KCODE = nil }
543
  end
544

  
545
  def test_ignorecase_warning
546
    assert_warning(/variable \$= is no longer effective; ignored/) { $= = nil }
547
    assert_warning(/variable \$= is no longer effective/) { $= }
548
  end
549

  
540 550
  def test_match_setter
541 551
    /foo/ =~ "foo"
542 552
    m = $~
543
-