lithium\tests\mocks\console\command\MockCreate::save PHP Method

save() public method

public save ( $template, $params = [] )
    public function save($template, $params = array())
    {
        return $this->_save($template, $params);
    }

Usage Example

 public function testSaveWithLibrary()
 {
     chdir($this->_testPath);
     $create = new MockCreate(array('request' => $this->request));
     $result = $create->save('test', array('namespace' => 'create_test\\tests\\cases\\models', 'use' => 'create_test\\models\\Post', 'class' => 'PostTest', 'methods' => "\tpublic function testCreate() {\n\n\t}\n"));
     $this->assertTrue($result);
     $result = $this->_testPath . '/create_test/tests/cases/models/PostTest.php';
     $this->assertTrue(file_exists($result));
     $this->_cleanUp();
 }
All Usage Examples Of lithium\tests\mocks\console\command\MockCreate::save
MockCreate