Skip to content

Commit 1604330

Browse files
committed
Implemented Windows-specific test for index generation ones.
git-svn-id: svn+ssh://rubyforge.org/var/svn/rubygems/trunk@1988 3d4018f9-ac1a-0410-99e9-8a154d859a19
1 parent 159af05 commit 1604330

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

test/test_gem_commands_generate_index_command.rb

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,24 @@ def test_execute
2828
end
2929

3030
def test_handle_options_directory
31+
return if win_platform?
3132
refute_equal '/nonexistent', @cmd.options[:directory]
3233

3334
@cmd.handle_options %w[--directory /nonexistent]
3435

3536
assert_equal '/nonexistent', @cmd.options[:directory]
3637
end
3738

39+
def test_handle_options_directory_windows
40+
return unless win_platform?
41+
42+
refute_equal '/nonexistent', @cmd.options[:directory]
43+
44+
@cmd.handle_options %w[--directory C:/nonexistent]
45+
46+
assert_equal 'C:/nonexistent', @cmd.options[:directory]
47+
end
48+
3849
def test_handle_options_invalid
3950
e = assert_raises OptionParser::InvalidOption do
4051
@cmd.handle_options %w[--no-modern --no-legacy]

0 commit comments

Comments
 (0)