getFileProcessorHandle() public static method

public static getFileProcessorHandle ( )
Exemplo n.º 1
0
 public function testRenderFile()
 {
     $entityLibrary = $this->dataLibrary->createEmpty();
     $entityLibrary->set('name', 'lib');
     $this->dataLibrary->create($entityLibrary);
     $entityBook = $this->dataBook->createEmpty();
     $entityBook->set('title', 'title');
     $entityBook->set('author', 'author');
     $entityBook->set('pages', 111);
     $entityBook->set('library', $entityLibrary->get('id'));
     $this->dataBook->create($entityBook);
     $fileProcessorHandle = TestDBSetup::getFileProcessorHandle();
     $this->dataBook->renderFile($entityBook, 'book', 'cover');
     $fileProcessorHandle->createFile->never()->called();
     $fileProcessorHandle->updateFile->never()->called();
     $fileProcessorHandle->deleteFile->never()->called();
     $fileProcessorHandle->renderFile->once()->called();
 }