-
Notifications
You must be signed in to change notification settings - Fork 177
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[test] fixed return type, add missing files
- Loading branch information
Showing
19 changed files
with
422 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class ApplicationTask extends sfBaseTask | ||
{ | ||
protected function configure() | ||
{ | ||
$this->addOption('application', null, sfCommandOption::PARAMETER_REQUIRED, '', true); | ||
} | ||
|
||
protected function execute($arguments = array(), $options = array()) | ||
{ | ||
if (!$this->configuration instanceof sfApplicationConfiguration) { | ||
throw new Exception('This task requires an application configuration be loaded.'); | ||
} | ||
} | ||
|
||
public function getServiceContainer() | ||
{ | ||
return parent::getServiceContainer(); | ||
} | ||
|
||
public function getRouting() | ||
{ | ||
return parent::getRouting(); | ||
} | ||
|
||
public function getMailer() | ||
{ | ||
return parent::getMailer(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class FakeValidator extends sfValidatorDecorator | ||
{ | ||
protected function getValidator() | ||
{ | ||
return 'foo'; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class FormListener | ||
{ | ||
public $events = array(); | ||
|
||
public function listen(sfEvent $event) | ||
{ | ||
$this->events[] = func_get_args(); | ||
} | ||
|
||
public function filter(sfEvent $event, $value) | ||
{ | ||
$this->events[] = func_get_args(); | ||
|
||
return $value; | ||
} | ||
|
||
public function reset() | ||
{ | ||
$this->events = array(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class ProjectLoader2 extends sfServiceContainerLoaderArray | ||
{ | ||
public function validate($content) | ||
{ | ||
return parent::validate($content); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class ProjectServiceContainer extends sfServiceContainer | ||
{ | ||
public $__bar; | ||
public $__foo_bar; | ||
public $__foo_baz; | ||
|
||
public function __construct() | ||
{ | ||
parent::__construct(); | ||
|
||
$this->__bar = new stdClass(); | ||
$this->__foo_bar = new stdClass(); | ||
$this->__foo_baz = new stdClass(); | ||
} | ||
|
||
protected function getBarService() | ||
{ | ||
return $this->__bar; | ||
} | ||
|
||
protected function getFooBarService() | ||
{ | ||
return $this->__foo_bar; | ||
} | ||
|
||
protected function getFoo_BazService() | ||
{ | ||
return $this->__foo_baz; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class TestForm extends sfFormSymfony | ||
{ | ||
public function configure() | ||
{ | ||
$this->setValidators(array( | ||
'first_name' => new sfValidatorString(), | ||
'last_name' => new sfValidatorString(), | ||
)); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class TestLogger extends sfFileLogger | ||
{ | ||
public function getTimeFormat() | ||
{ | ||
return $this->timeFormat; | ||
} | ||
|
||
protected function getPriority($priority) | ||
{ | ||
return '*'.$priority.'*'; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class TestTask extends sfBaseTask | ||
{ | ||
protected function execute($arguments = array(), $options = array()) {} | ||
|
||
public function reloadAutoload() | ||
{ | ||
parent::reloadAutoload(); | ||
} | ||
|
||
public function initializeAutoload(sfProjectConfiguration $configuration, $reload = false) | ||
{ | ||
parent::initializeAutoload($configuration, $reload); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class ValidatorChoiceTestIsEmpty extends sfValidatorChoice | ||
{ | ||
public function run($value) | ||
{ | ||
return $this->isEmpty($value); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class configuredView extends myView | ||
{ | ||
public static $isDecorated = false; | ||
|
||
public function initialize($context, $moduleName, $actionName, $viewName) | ||
{ | ||
$this->setDecorator(self::$isDecorated); | ||
|
||
parent::initialize($context, $moduleName, $actionName, $viewName); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class myFilesystem extends sfFilesystem | ||
{ | ||
public function calculateRelativeDir($from, $to) | ||
{ | ||
return parent::calculateRelativeDir($from, $to); | ||
} | ||
|
||
public function canonicalizePath($path) | ||
{ | ||
return parent::canonicalizePath($path); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class myLogger extends sfLogger | ||
{ | ||
public $log = ''; | ||
|
||
protected function doLog($message, $priority) | ||
{ | ||
$this->log .= $message; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class myLogger2 implements sfLoggerInterface | ||
{ | ||
public $log = ''; | ||
|
||
public function log($message, $priority = null) | ||
{ | ||
$this->log = $message; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class myLoggerWrapper extends sfLoggerWrapper | ||
{ | ||
public function getLogger() | ||
{ | ||
return $this->logger; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class myResponse2 extends sfResponse | ||
{ | ||
public function serialize() {} | ||
|
||
public function unserialize($serialized) {} | ||
|
||
public function __serialize() {} | ||
|
||
public function __unserialize($data) {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the symfony package. | ||
* (c) Fabien Potencier <[email protected]> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
class myView extends sfView | ||
{ | ||
public function execute() {} | ||
|
||
public function configure() {} | ||
|
||
public function getEngine() {} | ||
|
||
public function render() {} | ||
} |
Oops, something went wrong.