Граф коммитов

56 Коммитов

Автор SHA1 Сообщение Дата
nobu 16c40ec1a5 * test/fileutils/test_fileutils.rb (test_copy_stream):
IO.copy_stream support binmode only currently.
  [ruby-core:23724]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27614 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-05-04 09:38:21 +00:00
naruse d065e56c71 Follow reverting wrong commit; see r11156, r27400.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27550 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-04-29 12:56:41 +00:00
akr a967f738c8 * lib/matrix.rb: suppress warnings.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26417 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-01-25 22:08:29 +00:00
naruse 315cab1249 Explicitly use FileUtils.rm_f. [ruby-dev:39345]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26090 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-12-14 03:19:51 +00:00
nobu f2b68df43e * test/fileutils/test_fileutils.rb: fixed indent by splitting methods.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24993 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-09-18 02:20:39 +00:00
kazu 263abf2963 * test/fileutils/test_fileutils.rb: add a test for [ruby-dev:39345]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24987 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-09-17 22:08:32 +00:00
naruse f20d759cd0 * test/fileutils: use require_relative to require fileasserts.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24849 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-09-11 09:53:50 +00:00
nobu ee647e1b96 * lib/fileutils.rb (FileUtils::Entry_#copy_file): open the source
file first to ensure it can be copied.  [ruby-core:25498]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24823 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-09-09 13:02:04 +00:00
nobu 287a34ae0d * {ext,lib,test}/**/*.rb: removed trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22784 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2009-03-06 03:56:38 +00:00
yugui a8c3540b32 * dln.c: Ruby no longer supports Windows CE.
* eval.c: ditto.

* include/ruby/defines.h: ditto.

* include/ruby/win32.h: ditto.

* ruby.c: ditto.

* strftime.c: ditto.

* win32/Makefile.sub: ditto.

* win32/win32.c: ditto.

* ext/tk/extconf.rb: ditto.

* lib/fileutils.rb: ditto.

* test/fileutils/test_fileutils.rb: ditto.

* wince/*: removed.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19681 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-10-04 13:48:20 +00:00
yugui 8dd118c0db * djgpp/GNUmakefile.in: removed. Ruby no longer supports djgpp.
* djgpp/README.djgpp: ditto.

* djgpp/config.hin: ditto.

* djgpp/config.sed: ditto.

* djgpp/configure.bat: ditto.

* djgpp/mkver.sed: ditto.

* ext/Setup.dj: ditto.

* dln.c: removed djgpp supports.

* file.c: ditto.

* gc.c: ditto.

* io.c: ditto.

* process.c: ditto.

* ruby.c: ditto.

* signal.c: ditto.

* util.c: ditto.

* vm_core.h: ditto.

* lib/fileutils.rb: ditto.

* lib/mkmf.rb: ditto.

* ext/socket/socket.c: ditto.

* test/fileutils/test_fileutils.rb: ditto.

* test/ruby/test_env.rb: ditto.

* test/ruby/test_path.rb: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19678 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-10-04 13:25:12 +00:00
nobu 00b4a3f9c4 * test: assert_raises has been deprecated since a long time ago.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19536 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-09-24 17:44:39 +00:00
ryan 8e05c69aa1 Added changes needed for miniunit. usually from using internal calls that aren't needed anymore.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19504 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-09-23 21:39:21 +00:00
nobu 6c2108e2ac * io.c (copy_stream_fallback_body): use read method unless readpartial
is available.  [ruby-dev:36124]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19148 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-09-05 09:37:55 +00:00
akr a5c4480732 * test/fileutils/fileasserts.rb (assert_equal_timestamp): new assert
to test tv_sec only for filestamp resolution portability.
  (assert_same_entry): use assert_same_entry for mtime comparison.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13992 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-21 07:40:36 +00:00
akr 44b6b031ba previous change refined.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13974 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-19 16:19:12 +00:00
akr b4a0020707 * test/fileutils/fileasserts.rb (assert_equal_time): show nsec if
assertion fails but time.to_s equals.
  (assert_same_entry): use assert_equal_time.

* test/fileutils/test_fileutils.rb (test_install): use
  assert_equal_time.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13973 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-19 15:57:52 +00:00
akr 68543f3092 use ML ref. for assertion message.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13958 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-11-18 07:18:56 +00:00
ko1 a8d47615da * test/fileutils/test_fileutils.rb (check_singleton): fix to use
symbole instead of string.
* test/io/nonblock/test_flush.rb: enable tests.
* test/xmlrpc/test_webrick_server.rb: ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11743 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-14 16:53:00 +00:00
aamine a33aa9c9f4 * lib/fileutils.rb: fix visibility of FileUtils::NoWrite, Verbose, DryRun. [ruby-core:05954]
* test/fileutils/test_nowrite.rb: test it.
* test/fileutils/test_dryrun.rb: new file.
* test/fileutils/test_verbose.rb: new file.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9286 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-23 23:30:09 +00:00
aamine b7083f661d * lib/fileutils.rb: use module_function instead of single extend.
* test/fileutils/test_fileutils.rb: test existence of singleton methods.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@9215 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-18 20:59:29 +00:00
aamine 98855e4a27 * lib/fileutils.rb (remove_entry_secure): add documentation.
* lib/fileutils.rb (remove_entry_secure): should not invoke unlink(2) against a directory.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@8528 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-05-26 11:33:16 +00:00
aamine 55ec2ad163 * lib/fileutils.rb (rm_r): use lchown(2), not chown(2). [ruby-dev:26226]
* lib/fileutils.rb (cd): remove :noop option. (FEATURE CHANGE)
* lib/fileutils.rb (cp_r): should copy symlink as symlink, for also tree root. (FEATURE CHANGE)
* lib/fileutils.rb (cp_r): new option :dereference_root.
* lib/fileutils.rb: new method remove_entry.
* lib/fileutils.rb: new method remove_entry_secure.
* lib/fileutils.rb: add documentation.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@8525 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-05-25 22:41:32 +00:00
aamine af759b81a1 * lib/fileutils.rb (remove_file): ignore exceptions caused by chmod.
* lib/fileutils.rb (remove_dir): try to get rights to rmdir. [ruby-Bugs:1502]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@8330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-04-14 10:00:52 +00:00
aamine ad5830c4d0 * test/fileutils/test_fileutils.rb (setup): support BSD style directory group inheritance (again).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7835 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-01-26 15:13:03 +00:00
aamine 2d042f539b * test/fileutils/test_fileutils.rb: remove junk print statement.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7834 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-01-26 15:05:42 +00:00
aamine 19b9567c84 * test/fileutils/test_fileutils.rb (setup): support BSD style directory group inheritance. [ruby-dev:25440]
* test/fileutils/fileasserts.rb (assert_same_entry): show entry difference.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7833 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-01-26 15:03:37 +00:00
aamine b2625d914e * test/fileutils/test_fileutils.rb (test_copy_entry): copy_entry copies only file type, not mtime. [ruby-dev:25383]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7753 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-01-08 18:23:24 +00:00
aamine 0a4a9dbaea * lib/fileutils.rb (copy_stream): use read/write instead of sysread/syswrite, which allows duck typing. [ruby-dev:25369]
* lib/fileutils.rb (copy_stream): does NOT support nonblocking IO. [ruby-dev:25370]
* test/fileutils/test_fileutils.rb: test copy_entry, copy_file, copy_stream.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7699 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-01-01 07:22:04 +00:00
aamine 3cf02cc03e * test/fileutils/test_fileutils.rb (cp_r): tested wrong file name. [ruby-dev:25339]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7663 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-12-27 06:29:34 +00:00
aamine 95a5b4e9a4 * lib/fileutils.rb: (In previous commit) new method chown.
* lib/fileutils.rb: (In previous commit) new method chown_R.
* lib/fileutils.rb: (In previous commit) new method chmod_R wrongly added.  Removed now.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7461 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-12-04 12:29:55 +00:00
aamine 7c0370dcaf * lib/fileutils.rb (mkdir, mkdir_p): should chmod explicitly. [ruby-core:03881]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7460 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-12-04 11:46:24 +00:00
aamine ed1a776ae0 * lib/fileutils.rb (mkdir_p): should pass mode argument to Dir.mkdir. [ruby-dev:24242]
* test/fileutils/test_fileutils.rb: test it.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6879 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-09-10 06:56:20 +00:00
aamine 18c0a86cc6 * lib/fileutils.rb (cp_r): copies symlink to symlink, except cp_r root.
* lib/fileutils.rb: new method FileUtils.copy_entry.
* test/fileutils/test_fileutils.rb: more cp_r tests.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6747 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-08-08 21:35:11 +00:00
aamine 876aa19435 * lib/fileutils.rb (fu_list): Array() breaks pathes including "\n". [ruby-core:02843]
* test/fileutils/test_fileutils.rb (mkdir): test "\n" in path.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6268 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-05-07 12:04:19 +00:00
aamine bd4dc9f671 * test/fileutils/test_fileutils.rb (rm_f, rm_r): test :force flag.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6241 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-05-02 12:57:31 +00:00
aamine 3d92d0a135 * test/fileutils/test_fileutils.rb (test_rm_r): test if rm_rf can remove a symlink to the directory.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5940 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-03-10 13:41:43 +00:00
aamine ddc22d3596 * test/fileutils/test_fileutils.rb: rescue SystemCallError instead of EINVAL. File.link may raise EACCES on network file systems.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5686 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-02-13 03:27:01 +00:00
aamine 0c30c6836b * test/fileutils/test_fileutils.rb: File.link raises EINVAL on Win9x. [ruby-dev:22713]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5685 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-02-12 20:21:24 +00:00
nahi 04b5228aba * test/*: remove $: trick. [ruby-dev:22763] use test/runner.rb to
run test.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5580 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2004-01-29 13:22:27 +00:00
nobu 52975bb7a7 * test/fileutils/test_fileutils.rb: should not create any
files or directories in current directory.  [ruby-talk:88724]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5271 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-12-24 02:26:44 +00:00
aamine 232b4c2073 * lib/fileutils.rb (mkdir): remove trailing `/' from pathes.
* lib/fileutils.rb (rmdir): ditto. [ruby-dev:22238]
* lib/fileutils.rb (rmdir_r): ditto.
* lib/fileutils.rb (fu_copy_dir): check if it is a directory after mkdir(2).


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5176 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-12-12 10:33:24 +00:00
aamine 4f95ee2458 * test/fileutils/test_fileutils.rb (test_mkdir_p): test expand_path'ed path.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-12-11 12:07:17 +00:00
aamine 8c95664355 * test/fileutils/test_fileutils.rb (test_cp): test if the error is kind of SystemCallError. It is needless details that which errno is set on each systems.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5108 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-12-04 05:09:47 +00:00
aamine 76eab3527f * test/fileutils/test_fileutils.rb: check if Pathnames are usable for arguments.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5082 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-12-02 11:03:37 +00:00
aamine e5690fcd6d * lib/fileutils.rb (fu_each_src_dest0): call #to_str to allow Pathname for arguments. [ruby-core:01795]
* test/fileutils/test_fileutils.rb: does much strict test on "same" files detecting.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5071 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-12-01 05:18:46 +00:00
eban f56d1d8777 * test/fileutils/test_fileutils.rb (test_ln_s): should be a file, not
a directory.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5054 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-11-28 12:46:36 +00:00
eban f3e1738d9c * test/fileutils/test_fileutils.rb: should take the existing symbolic
link for OpenBSD.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5034 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-11-26 06:42:52 +00:00
aamine 7e42e5c01b * test/fileutils/test_fileutils.rb: do test in more deep directory.
* test/fileutils/test_nowrite.rb: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5028 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-11-25 11:02:30 +00:00
aamine 0452420e4c * test/fileutils/test_fileutils.rb: chdir Dir.tmpdir before each test. [ruby-dev:22045]
* test/fileutils/test_nowrite.rb: ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5025 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2003-11-25 09:13:58 +00:00