|
54 | 54 | it "raises an ArgumentError if 4 or more arguments are passed when no block given" do
|
55 | 55 | lambda { [].fill('a') }.should_not raise_error(ArgumentError)
|
56 | 56 |
|
57 |
| - ruby_bug "#", "1.8.6.277" do |
58 |
| - lambda { [].fill('a', 1) }.should_not raise_error(ArgumentError) |
59 |
| - end |
| 57 | + lambda { [].fill('a', 1) }.should_not raise_error(ArgumentError) |
60 | 58 |
|
61 | 59 | lambda { [].fill('a', 1, 2) }.should_not raise_error(ArgumentError)
|
62 | 60 | lambda { [].fill('a', 1, 2, true) }.should raise_error(ArgumentError)
|
|
69 | 67 | it "raises an ArgumentError if 3 or more arguments are passed when a block given" do
|
70 | 68 | lambda { [].fill() {|i|} }.should_not raise_error(ArgumentError)
|
71 | 69 |
|
72 |
| - ruby_bug "#", "1.8.6.277" do |
73 |
| - lambda { [].fill(1) {|i|} }.should_not raise_error(ArgumentError) |
74 |
| - end |
| 70 | + lambda { [].fill(1) {|i|} }.should_not raise_error(ArgumentError) |
75 | 71 |
|
76 | 72 | lambda { [].fill(1, 2) {|i|} }.should_not raise_error(ArgumentError)
|
77 | 73 | lambda { [].fill(1, 2, true) {|i|} }.should raise_error(ArgumentError)
|
|
163 | 159 | [1, 2, 3, 4, 5].fill('a', 2, 0).should == [1, 2, 3, 4, 5]
|
164 | 160 | [1, 2, 3, 4, 5].fill('a', -2, 0).should == [1, 2, 3, 4, 5]
|
165 | 161 |
|
166 |
| - ruby_bug "#", "1.8.6.277" do |
167 |
| - [1, 2, 3, 4, 5].fill('a', 2, -2).should == [1, 2, 3, 4, 5] |
168 |
| - [1, 2, 3, 4, 5].fill('a', -2, -2).should == [1, 2, 3, 4, 5] |
169 |
| - end |
| 162 | + [1, 2, 3, 4, 5].fill('a', 2, -2).should == [1, 2, 3, 4, 5] |
| 163 | + [1, 2, 3, 4, 5].fill('a', -2, -2).should == [1, 2, 3, 4, 5] |
170 | 164 |
|
171 | 165 | [1, 2, 3, 4, 5].fill(2, 0, &@never_passed).should == [1, 2, 3, 4, 5]
|
172 | 166 | [1, 2, 3, 4, 5].fill(-2, 0, &@never_passed).should == [1, 2, 3, 4, 5]
|
173 | 167 |
|
174 |
| - ruby_bug "#", "1.8.6.277" do |
175 |
| - [1, 2, 3, 4, 5].fill(2, -2, &@never_passed).should == [1, 2, 3, 4, 5] |
176 |
| - [1, 2, 3, 4, 5].fill(-2, -2, &@never_passed).should == [1, 2, 3, 4, 5] |
177 |
| - end |
| 168 | + [1, 2, 3, 4, 5].fill(2, -2, &@never_passed).should == [1, 2, 3, 4, 5] |
| 169 | + [1, 2, 3, 4, 5].fill(-2, -2, &@never_passed).should == [1, 2, 3, 4, 5] |
178 | 170 | end
|
179 | 171 |
|
180 |
| - ruby_bug "#", "1.8.6.277" do |
181 |
| - # See: http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/17481 |
182 |
| - it "does not raise an exception if the given length is negative and its absolute value does not exceed the index" do |
183 |
| - lambda { [1, 2, 3, 4].fill('a', 3, -1)}.should_not raise_error(ArgumentError) |
184 |
| - lambda { [1, 2, 3, 4].fill('a', 3, -2)}.should_not raise_error(ArgumentError) |
185 |
| - lambda { [1, 2, 3, 4].fill('a', 3, -3)}.should_not raise_error(ArgumentError) |
| 172 | + # See: http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/17481 |
| 173 | + it "does not raise an exception if the given length is negative and its absolute value does not exceed the index" do |
| 174 | + lambda { [1, 2, 3, 4].fill('a', 3, -1)}.should_not raise_error(ArgumentError) |
| 175 | + lambda { [1, 2, 3, 4].fill('a', 3, -2)}.should_not raise_error(ArgumentError) |
| 176 | + lambda { [1, 2, 3, 4].fill('a', 3, -3)}.should_not raise_error(ArgumentError) |
186 | 177 |
|
187 |
| - lambda { [1, 2, 3, 4].fill(3, -1, &@never_passed)}.should_not raise_error(ArgumentError) |
188 |
| - lambda { [1, 2, 3, 4].fill(3, -2, &@never_passed)}.should_not raise_error(ArgumentError) |
189 |
| - lambda { [1, 2, 3, 4].fill(3, -3, &@never_passed)}.should_not raise_error(ArgumentError) |
190 |
| - end |
| 178 | + lambda { [1, 2, 3, 4].fill(3, -1, &@never_passed)}.should_not raise_error(ArgumentError) |
| 179 | + lambda { [1, 2, 3, 4].fill(3, -2, &@never_passed)}.should_not raise_error(ArgumentError) |
| 180 | + lambda { [1, 2, 3, 4].fill(3, -3, &@never_passed)}.should_not raise_error(ArgumentError) |
| 181 | + end |
191 | 182 |
|
192 |
| - it "does not raise an exception even if the given length is negative and its absolute value exceeds the index" do |
193 |
| - lambda { [1, 2, 3, 4].fill('a', 3, -4)}.should_not raise_error(ArgumentError) |
194 |
| - lambda { [1, 2, 3, 4].fill('a', 3, -5)}.should_not raise_error(ArgumentError) |
195 |
| - lambda { [1, 2, 3, 4].fill('a', 3, -10000)}.should_not raise_error(ArgumentError) |
| 183 | + it "does not raise an exception even if the given length is negative and its absolute value exceeds the index" do |
| 184 | + lambda { [1, 2, 3, 4].fill('a', 3, -4)}.should_not raise_error(ArgumentError) |
| 185 | + lambda { [1, 2, 3, 4].fill('a', 3, -5)}.should_not raise_error(ArgumentError) |
| 186 | + lambda { [1, 2, 3, 4].fill('a', 3, -10000)}.should_not raise_error(ArgumentError) |
196 | 187 |
|
197 |
| - lambda { [1, 2, 3, 4].fill(3, -4, &@never_passed)}.should_not raise_error(ArgumentError) |
198 |
| - lambda { [1, 2, 3, 4].fill(3, -5, &@never_passed)}.should_not raise_error(ArgumentError) |
199 |
| - lambda { [1, 2, 3, 4].fill(3, -10000, &@never_passed)}.should_not raise_error(ArgumentError) |
200 |
| - end |
| 188 | + lambda { [1, 2, 3, 4].fill(3, -4, &@never_passed)}.should_not raise_error(ArgumentError) |
| 189 | + lambda { [1, 2, 3, 4].fill(3, -5, &@never_passed)}.should_not raise_error(ArgumentError) |
| 190 | + lambda { [1, 2, 3, 4].fill(3, -10000, &@never_passed)}.should_not raise_error(ArgumentError) |
201 | 191 | end
|
202 | 192 |
|
203 | 193 | it "tries to convert the second and third arguments to Integers using #to_int" do
|
|
0 commit comments