@@ -78,24 +78,6 @@ public function testCreateFromNsdirObject(): void {
7878 $ this ->assertEquals (new ClassFilesIA_Empty (), $ f (__DIR__ . '/non/existing/subdir ' ));
7979 }
8080
81- public function testWithRealpathRoot (): void {
82- $ c = fn (string $ dir ) => new ClassFilesIA_NamespaceDirectoryPsr4 ($ dir , 'Acme\Zoo \\' );
83- $ realpath = realpath (__DIR__ ) ?: $ this ->fail ();
84- $ crooked_path = __DIR__ . '/../src ' ;
85- $ this ->assertFalse (str_ends_with ($ realpath , '/../src ' ));
86- $ obj_with_realpath = $ c ($ realpath );
87- $ this ->assertEquals ($ obj_with_realpath , $ c ($ crooked_path )->withRealpathRoot ());
88-
89- // A new clone is returned even though values are the same.
90- // Perhaps this will change in the future.
91- $ this ->assertEquals ($ obj_with_realpath , $ obj_with_realpath ->withRealpathRoot ());
92- $ this ->assertNotSame ($ obj_with_realpath , $ obj_with_realpath ->withRealpathRoot ());
93-
94- // Test effect on the iterator.
95- $ this ->assertSame ($ realpath , dirname ($ obj_with_realpath ->getIterator ()->key ()));
96- $ this ->assertSame ($ crooked_path , dirname ($ c ($ crooked_path )->getIterator ()->key ()));
97- }
98-
9981 /**
10082 * @throws \ReflectionException
10183 */
@@ -117,7 +99,6 @@ public function testGetIterator(): void {
11799 public function testEmpty (): void {
118100 $ classFilesIA = new ClassFilesIA_Empty ();
119101 $ this ->assertFalse ($ classFilesIA ->getIterator ()->valid ());
120- $ this ->assertSame ($ classFilesIA , $ classFilesIA ->withRealpathRoot ());
121102 }
122103
123104 /**
@@ -140,17 +121,6 @@ public function testConcat(): void {
140121 [__DIR__ . '/Fixtures/Acme/Animal/RedSquirrel.php ' , RedSquirrel::class],
141122 [__DIR__ . '/Fixtures/Acme/Plant/Tree/Fig.php ' , Fig::class],
142123 ], $ actual );
143-
144- $ this ->assertEquals (
145- new ClassFilesIA_Concat ([
146- ClassFilesIA::psr4 (realpath (__DIR__ ) ?: '? ' , 'Acme\Zoo ' ),
147- ClassFilesIA::psr4 (realpath (__DIR__ . '/Fixtures ' ) ?: '? ' , 'Acme\Zoo ' ),
148- ]),
149- (new ClassFilesIA_Concat ([
150- ClassFilesIA::psr4 (__DIR__ . '/../src ' , 'Acme\Zoo ' ),
151- ClassFilesIA::psr4 (__DIR__ . '/../src/Fixtures ' , 'Acme\Zoo ' ),
152- ]))->withRealpathRoot (),
153- );
154124 }
155125
156126 public function testFactoryPsr4 (): void {
0 commit comments