File tree Expand file tree Collapse file tree
tests/php/Unit/Service/File Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -121,6 +121,7 @@ public function testLoadMetadataWithPages(): void {
121121 public function testLoadMetadataLogsWarningOnError (): void {
122122 $ file = new File ();
123123 $ file ->setId (1 );
124+ $ file ->setName ('document.pdf ' );
124125 $ file ->setUserId ('user123 ' );
125126 $ file ->setSignedNodeId (123 );
126127
@@ -139,8 +140,9 @@ public function testLoadMetadataLogsWarningOnError(): void {
139140 $ service = $ this ->getService ();
140141 $ service ->loadMetadata ($ file , $ fileData );
141142
142- // Should not throw exception
143- $ this ->assertTrue (true );
143+ $ this ->assertIsArray ($ fileData ->metadata );
144+ $ this ->assertSame (0 , $ fileData ->metadata ['p ' ]);
145+ $ this ->assertSame ('pdf ' , $ fileData ->metadata ['extension ' ]);
144146 }
145147
146148 #[DataProvider('provideNodeIdPrecedenceScenarios ' )]
You can’t perform that action at this time.
0 commit comments