Skip to content

Commit 2ac9256

Browse files
committed
Use omit instead of skip for test-unit.
1 parent f48c390 commit 2ac9256

9 files changed

+19
-21
lines changed

test/rdoc/helper.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,4 @@ def verbose_capture_output
201201
end
202202
end
203203
end
204-
205-
alias skip omit
206204
end

test/rdoc/test_rdoc_generator_json_index.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ def test_generate_gzipped
168168
begin
169169
require 'zlib'
170170
rescue LoadError
171-
skip "no zlib"
171+
omit "no zlib"
172172
end
173173
@g.generate
174174
@g.generate_gzipped

test/rdoc/test_rdoc_i18n_locale.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def test_load_existent_po
3232
begin
3333
require 'gettext/po_parser'
3434
rescue LoadError
35-
skip 'gettext gem is not found'
35+
omit 'gettext gem is not found'
3636
end
3737

3838
fr_locale_dir = File.join @locale_dir, 'fr'

test/rdoc/test_rdoc_options.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ def teardown
1717
end
1818

1919
def test_check_files
20-
skip "assumes UNIX permission model" if /mswin|mingw/ =~ RUBY_PLATFORM
21-
skip "assumes that euid is not root" if Process.euid == 0
20+
omit "assumes UNIX permission model" if /mswin|mingw/ =~ RUBY_PLATFORM
21+
omit "assumes that euid is not root" if Process.euid == 0
2222

2323
out, err = capture_output do
2424
temp_dir do

test/rdoc/test_rdoc_parser.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ def test_class_for_executable
104104
end
105105

106106
def test_class_for_forbidden
107-
skip 'chmod not supported' if Gem.win_platform?
107+
omit 'chmod not supported' if Gem.win_platform?
108108

109109
tf = Tempfile.open 'forbidden' do |io|
110110
begin

test/rdoc/test_rdoc_rdoc.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ def test_normalized_file_list_not_modified
163163

164164
def test_normalized_file_list_non_file_directory
165165
dev = File::NULL
166-
skip "#{dev} is not a character special" unless
166+
omit "#{dev} is not a character special" unless
167167
File.chardev? dev
168168

169169
files = nil
@@ -349,8 +349,8 @@ def test_parse_file_encoding
349349
end
350350

351351
def test_parse_file_forbidden
352-
skip 'chmod not supported' if Gem.win_platform?
353-
skip "assumes that euid is not root" if Process.euid == 0
352+
omit 'chmod not supported' if Gem.win_platform?
353+
omit "assumes that euid is not root" if Process.euid == 0
354354

355355
@rdoc.store = RDoc::Store.new
356356

test/rdoc/test_rdoc_ri_driver.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1029,7 +1029,7 @@ def test_find_store
10291029
end
10301030

10311031
def test_did_you_mean
1032-
skip 'skip test with did_you_men' unless defined? DidYouMean::SpellChecker
1032+
omit 'omit test with did_you_men' unless defined? DidYouMean::SpellChecker
10331033

10341034
util_ancestors_store
10351035

@@ -1227,7 +1227,7 @@ def _test_page # this test doesn't do anything anymore :(
12271227

12281228
with_dummy_pager do
12291229
@driver.page do |io|
1230-
skip "couldn't find a standard pager" if io == $stdout
1230+
omit "couldn't find a standard pager" if io == $stdout
12311231

12321232
assert @driver.paging?
12331233
end
@@ -1239,7 +1239,7 @@ def _test_page # this test doesn't do anything anymore :(
12391239
# this test is too fragile. Perhaps using Process.spawn will make this
12401240
# reliable
12411241
def _test_page_in_presence_of_child_status
1242-
skip 'this test hangs on travis-ci.org' if ENV['CI']
1242+
omit 'this test hangs on travis-ci.org' if ENV['CI']
12431243
@driver.use_stdout = false
12441244

12451245
with_dummy_pager do
@@ -1407,7 +1407,7 @@ def _test_setup_pager # this test doesn't do anything anymore :(
14071407

14081408
pager = with_dummy_pager do @driver.setup_pager end
14091409

1410-
skip "couldn't find a standard pager" unless pager
1410+
omit "couldn't find a standard pager" unless pager
14111411

14121412
assert @driver.paging?
14131413
ensure

test/rdoc/test_rdoc_rubygems_hook.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ def setup
2222
begin
2323
RDoc::RubygemsHook.load_rdoc
2424
rescue Gem::DocumentError => e
25-
skip e.message
25+
omit e.message
2626
end
2727

2828
Gem.configuration[:rdoc] = nil
@@ -200,8 +200,8 @@ def test_remove
200200
end
201201

202202
def test_remove_unwritable
203-
skip 'chmod not supported' if Gem.win_platform?
204-
skip "assumes that euid is not root" if Process.euid == 0
203+
omit 'chmod not supported' if Gem.win_platform?
204+
omit "assumes that euid is not root" if Process.euid == 0
205205

206206
FileUtils.mkdir_p @a.base_dir
207207
FileUtils.chmod 0, @a.base_dir
@@ -230,8 +230,8 @@ def test_setup
230230
end
231231

232232
def test_setup_unwritable
233-
skip 'chmod not supported' if Gem.win_platform?
234-
skip "assumes that euid is not root" if Process.euid == 0
233+
omit 'chmod not supported' if Gem.win_platform?
234+
omit "assumes that euid is not root" if Process.euid == 0
235235

236236
FileUtils.mkdir_p @a.doc_dir
237237
FileUtils.chmod 0, @a.doc_dir

test/rdoc/test_rdoc_servlet.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ def test_generator_for
294294
end
295295

296296
def test_if_modified_since
297-
skip 'File.utime on directory not supported' if Gem.win_platform?
297+
omit 'File.utime on directory not supported' if Gem.win_platform?
298298

299299
temp_dir do
300300
now = Time.now
@@ -307,7 +307,7 @@ def test_if_modified_since
307307
end
308308

309309
def test_if_modified_since_not_modified
310-
skip 'File.utime on directory not supported' if Gem.win_platform?
310+
omit 'File.utime on directory not supported' if Gem.win_platform?
311311

312312
temp_dir do
313313
now = Time.now

0 commit comments

Comments
 (0)