[前][次][番号順一覧][スレッド一覧]

ruby-changes:46579

From: usa <ko1@a...>
Date: Sat, 13 May 2017 05:10:23 +0900 (JST)
Subject: [ruby-changes:46579] usa:r58695 (trunk): `notepad.exe` does not always exist in `C:\Windows`

usa	2017-05-13 05:10:16 +0900 (Sat, 13 May 2017)

  New Revision: 58695

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=58695

  Log:
    `notepad.exe` does not always exist in `C:\Windows`
    
    Use `%WINDIR%\system32\drivers\etc\services` instead of `notepad.exe`.

  Modified files:
    trunk/spec/rubyspec/shared/file/readable.rb
Index: spec/rubyspec/shared/file/readable.rb
===================================================================
--- spec/rubyspec/shared/file/readable.rb	(revision 58694)
+++ spec/rubyspec/shared/file/readable.rb	(revision 58695)
@@ -2,7 +2,7 @@ describe :file_readable, shared: true do https://github.com/ruby/ruby/blob/trunk/spec/rubyspec/shared/file/readable.rb#L2
   before :each do
     @file = tmp('i_exist')
     platform_is :windows do
-      @file2 = "C:\\windows\\notepad.exe"
+      @file2 = File.join(ENV["WINDIR"], "system32/drivers/etc/services").tr(File::SEPARATOR, File::ALT_SEPARATOR)
     end
     platform_is_not :windows do
       @file2 = "/etc/passwd"

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]