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

Warn non-nil $/ [Feature #14240]

This commit is contained in:
Nobuyoshi Nakada 2020-01-21 08:37:44 +09:00
parent 6298ec2875
commit 8a7e0aaaef
No known key found for this signature in database
GPG key ID: 4BC7D6DF58D8DF60
Notes: git 2020-02-23 16:49:04 +09:00
18 changed files with 75 additions and 29 deletions

View file

@ -16,7 +16,7 @@ describe "IO#puts" do
ScratchPad.clear
@io.close if @io
rm_r @name
$/ = @before_separator
suppress_warning {$/ = @before_separator}
end
it "writes just a newline when given no args" do
@ -105,7 +105,7 @@ describe "IO#puts" do
end
it "ignores the $/ separator global" do
$/ = ":"
suppress_warning {$/ = ":"}
@io.puts(5).should == nil
ScratchPad.recorded.should == "5\n"
end