|
1 | 1 | require_relative "test_helper" |
2 | | -require 'pathname' |
| 2 | +require "pathname" unless defined?(Pathname) |
3 | 3 |
|
4 | 4 | class PathnameSingletonTest < Test::Unit::TestCase |
5 | 5 | include TestHelper |
@@ -314,17 +314,6 @@ def test_file? |
314 | 314 | Pathname('/unknown'), :file? |
315 | 315 | end |
316 | 316 |
|
317 | | - def test_find |
318 | | - assert_send_type '() { (Pathname) -> untyped } -> nil', |
319 | | - Pathname(__dir__), :find do end |
320 | | - assert_send_type '(ignore_error: bool) -> Enumerator[Pathname, nil]', |
321 | | - Pathname(__dir__), :find, ignore_error: true |
322 | | - assert_send_type '(ignore_error: Symbol) -> Enumerator[Pathname, nil]', |
323 | | - Pathname(__dir__), :find, ignore_error: :true |
324 | | - assert_send_type '() -> Enumerator[Pathname, nil]', |
325 | | - Pathname(__dir__), :find |
326 | | - end |
327 | | - |
328 | 317 | def test_fnmatch |
329 | 318 | assert_send_type '(String) -> bool', |
330 | 319 | Pathname('foo'), :fnmatch, 'fo*' |
@@ -638,15 +627,6 @@ def test_rmdir |
638 | 627 | end |
639 | 628 | end |
640 | 629 |
|
641 | | - def test_rmtree |
642 | | - Dir.mktmpdir do |dir| |
643 | | - target = Pathname(dir).join('target') |
644 | | - target.mkdir |
645 | | - assert_send_type '() -> Pathname', |
646 | | - target, :rmtree |
647 | | - end |
648 | | - end |
649 | | - |
650 | 630 | def test_root? |
651 | 631 | assert_send_type '() -> bool', |
652 | 632 | Pathname('.'), :root? |
|
0 commit comments