Exemple #1
0
 /**
  * Split a file containing several classes into a set of files
  * @param string $oldFilePath the path to the file to be split
  * @param string $outputPath the path where the files should be saved
  */
 public function setSplitClassFiles($outputPath)
 {
     $this->_listeners[] = $this->_operationsFactory->getOperation('Scisr_Operations_SplitClassFile', $outputPath);
     if (!is_dir($outputPath) || !is_writeable($outputPath)) {
         $msg = $outputPath . ' is not writeable or a directory.';
     }
     if (isset($msg)) {
         $msg = "File \"{$outputPath}\" " . $msg;
         $this->sendOutput($msg);
     }
 }
Exemple #2
0
 public function testReturnsCollaboratorsForManualWiring()
 {
     $factory = new Scisr_Operations_Factory(array($stdClass = new stdClass()));
     $this->assertSame($stdClass, $factory->getCollaborator('stdClass'));
 }