File tree Expand file tree Collapse file tree 4 files changed +1
-22
lines changed
Expand file tree Collapse file tree 4 files changed +1
-22
lines changed Original file line number Diff line number Diff line change 1010use Hyde \Support \Concerns \Serializable ;
1111use Hyde \Support \Contracts \SerializableContract ;
1212use function pathinfo ;
13- use Stringable ;
1413
1514/**
1615 * Filesystem abstraction for a file stored in the project.
1716 *
1817 * @see \Hyde\Framework\Testing\Feature\Support\ProjectFileTest
1918 */
20- abstract class ProjectFile implements SerializableContract, Stringable
19+ abstract class ProjectFile implements SerializableContract
2120{
2221 use Serializable;
2322
@@ -39,11 +38,6 @@ public function __construct(string $path)
3938 $ this ->path = Hyde::pathToRelative ($ path );
4039 }
4140
42- public function __toString (): string
43- {
44- return $ this ->path ;
45- }
46-
4741 /**
4842 * @return array{name: string, path: string}
4943 */
Original file line number Diff line number Diff line change @@ -36,11 +36,6 @@ public function test_absolute_path_is_normalized_to_relative()
3636 $ this ->assertEquals ('foo ' , MediaFile::make (Hyde::path ('foo ' ))->path );
3737 }
3838
39- public function test_to_string_returns_path ()
40- {
41- $ this ->assertSame ('foo ' , (string ) MediaFile::make ('foo ' ));
42- }
43-
4439 public function test_get_name_returns_name_of_file ()
4540 {
4641 $ this ->assertSame ('foo.txt ' , MediaFile::make ('foo.txt ' )->getName ());
Original file line number Diff line number Diff line change @@ -35,11 +35,6 @@ public function test_absolute_path_is_normalized_to_relative()
3535 $ this ->assertEquals ('foo ' , ProjectFileTestClass::make (Hyde::path ('foo ' ))->path );
3636 }
3737
38- public function test_to_string_returns_path ()
39- {
40- $ this ->assertSame ('foo ' , (string ) ProjectFileTestClass::make ('foo ' ));
41- }
42-
4338 public function test_get_name_returns_name_of_file ()
4439 {
4540 $ this ->assertSame ('foo.txt ' , ProjectFileTestClass::make ('foo.txt ' )->getName ());
Original file line number Diff line number Diff line change @@ -54,11 +54,6 @@ public function test_absolute_path_is_normalized_to_relative()
5454 $ this ->assertEquals ('foo ' , SourceFile::make (Hyde::path ('foo ' ))->path );
5555 }
5656
57- public function test_to_string_returns_path ()
58- {
59- $ this ->assertSame ('foo ' , (string ) SourceFile::make ('foo ' ));
60- }
61-
6257 public function test_get_name_returns_name_of_file ()
6358 {
6459 $ this ->assertSame ('foo.txt ' , SourceFile::make ('foo.txt ' )->getName ());
You can’t perform that action at this time.
0 commit comments