Skip to content

Commit 4336b6b

Browse files
committed
removed needless condition for old ruby
1 parent 3b57752 commit 4336b6b

File tree

3 files changed

+0
-21
lines changed

3 files changed

+0
-21
lines changed

lib/rdoc/markup/formatter_test_case.rb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,6 @@ def test_accept_heading_2
177177
# Calls accept_heading_3 with a level 3 RDoc::Markup::Heading
178178

179179
def test_accept_heading_3
180-
# HACK this doesn't belong here
181-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
182-
183180
@to.start_accepting
184181

185182
@to.accept_heading @RM::Heading.new(3, 'Hello')
@@ -765,4 +762,3 @@ def test_list_verbatim # HACK overblown
765762
end
766763

767764
end
768-

lib/rdoc/test_case.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,8 +177,6 @@ def raw *contents
177177
# Depends upon Dir.mktmpdir
178178

179179
def temp_dir
180-
skip "No Dir::mktmpdir, upgrade your ruby" unless Dir.respond_to? :mktmpdir
181-
182180
Dir.mktmpdir do |temp_dir|
183181
Dir.chdir temp_dir do
184182
yield temp_dir

test/test_rdoc_markup_to_bs.rb

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ def accept_document
2525
end
2626

2727
def accept_heading
28-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
2928
assert_equal "===== H\bHe\bel\bll\blo\bo\n", @to.res.join
3029
end
3130

@@ -216,37 +215,30 @@ def start_accepting
216215
end
217216

218217
def accept_heading_1
219-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
220218
assert_equal "= H\bHe\bel\bll\blo\bo\n", @to.end_accepting
221219
end
222220

223221
def accept_heading_2
224-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
225222
assert_equal "== H\bHe\bel\bll\blo\bo\n", @to.end_accepting
226223
end
227224

228225
def accept_heading_3
229-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
230226
assert_equal "=== H\bHe\bel\bll\blo\bo\n", @to.end_accepting
231227
end
232228

233229
def accept_heading_4
234-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
235230
assert_equal "==== H\bHe\bel\bll\blo\bo\n", @to.end_accepting
236231
end
237232

238233
def accept_heading_indent
239-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
240234
assert_equal " = H\bHe\bel\bll\blo\bo\n", @to.end_accepting
241235
end
242236

243237
def accept_heading_b
244-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
245238
assert_equal "= H\bHe\bel\bll\blo\bo\n", @to.end_accepting
246239
end
247240

248241
def accept_heading_suppressed_crossref
249-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
250242
assert_equal "= H\bHe\bel\bll\blo\bo\n", @to.end_accepting
251243
end
252244

@@ -264,24 +256,20 @@ def accept_list_item_start_note_multi_label
264256
end
265257

266258
def accept_paragraph_b
267-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
268259
assert_equal "reg b\bbo\bol\bld\bd \b w\bwo\bor\brd\bds\bs reg\n",
269260
@to.end_accepting
270261
end
271262

272263
def accept_paragraph_br
273-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
274264
assert_equal "one\ntwo\n", @to.end_accepting
275265
end
276266

277267
def accept_paragraph_break
278-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
279268
assert_equal "hello\nworld\n",
280269
@to.end_accepting
281270
end
282271

283272
def accept_paragraph_i
284-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
285273
assert_equal "reg _\bi_\bt_\ba_\bl_\bi_\bc_\b _\bw_\bo_\br_\bd_\bs reg\n",
286274
@to.end_accepting
287275
end
@@ -301,12 +289,10 @@ def accept_paragraph_plus
301289
end
302290

303291
def accept_paragraph_star
304-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
305292
assert_equal "reg b\bbo\bol\bld\bd reg\n", @to.end_accepting
306293
end
307294

308295
def accept_paragraph_underscore
309-
skip "No String#chars, upgrade your ruby" unless ''.respond_to? :chars
310296
assert_equal "reg _\bi_\bt_\ba_\bl_\bi_\bc reg\n", @to.end_accepting
311297
end
312298

@@ -364,4 +350,3 @@ def list_verbatim
364350
end
365351

366352
end
367-

0 commit comments

Comments
 (0)