diff options
| author | Yukihiro Matsumoto <[email protected]> | 2012-06-12 12:29:20 +0900 |
|---|---|---|
| committer | Yukihiro Matsumoto <[email protected]> | 2012-06-12 12:29:20 +0900 |
| commit | 5937c29281d9bf51ca85b79c8f3dea204909a073 (patch) | |
| tree | e66e80f5c9bb157ab6d1def59ebe68583fc1302d /test | |
| parent | b32e586099d8a59bd497031f27e9763b028c0bad (diff) | |
| download | mruby-5937c29281d9bf51ca85b79c8f3dea204909a073.tar.gz mruby-5937c29281d9bf51ca85b79c8f3dea204909a073.zip | |
s.split(nil) should work like s.split()
Diffstat (limited to 'test')
| -rw-r--r-- | test/t/string.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/t/string.rb b/test/t/string.rb index 718b005a9..c422133e3 100644 --- a/test/t/string.rb +++ b/test/t/string.rb @@ -277,9 +277,11 @@ assert('String#split', '15.2.10.5.35') do # without RegExp behavior is actually unspecified a = 'abc abc abc'.split b = 'a,b,c,,d'.split(',') + c = 'abc abc abc'.split(nil) a == ['abc', 'abc', 'abc'] and - b == ["a", "b", "c", "", "d"] + b == ["a", "b", "c", "", "d"] and + c == ['abc', 'abc', 'abc'] end # TODO ATM broken assert('String#sub', '15.2.10.5.36') do |
