1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
This commit is contained in:
Benoit Daloze 2019-04-28 23:20:11 +02:00
parent 994833085a
commit 79671ec57e
135 changed files with 4415 additions and 4885 deletions

View file

@ -43,10 +43,8 @@ describe "String#=~" do
$~.should == nil
end
with_feature :encoding do
it "returns the character index of a found match" do
("こにちわ" =~ //).should == 1
end
it "returns the character index of a found match" do
("こにちわ" =~ //).should == 1
end
end
@ -64,10 +62,8 @@ describe "String#match" do
"01234".match(/(.).(.)/, 1).captures.should == ["1", "3"]
end
with_feature :encoding do
it "uses the start as a character offset" do
"零一二三四".match(/(.).(.)/, 1).captures.should == ["", ""]
end
it "uses the start as a character offset" do
"零一二三四".match(/(.).(.)/, 1).captures.should == ["", ""]
end
end
@ -76,10 +72,8 @@ describe "String#match" do
"01234".match(/(.).(.)/, -4).captures.should == ["1", "3"]
end
with_feature :encoding do
it "uses the start as a character offset" do
"零一二三四".match(/(.).(.)/, -4).captures.should == ["", ""]
end
it "uses the start as a character offset" do
"零一二三四".match(/(.).(.)/, -4).captures.should == ["", ""]
end
end
end