Author: ts Date: Mon Nov 26 12:34:01 2007 New Revision: 6803 Log: - Added missing test case for plugin API. - Marked plugin API private for now. # As discussed on the mailinglist.
Added: trunk/Webdav/tests/plugin_hooks_test.php (with props) Modified: trunk/Webdav/src/plugin_configuration.php trunk/Webdav/src/plugin_parameters.php trunk/Webdav/src/plugin_registry.php Modified: trunk/Webdav/src/plugin_configuration.php ============================================================================== --- trunk/Webdav/src/plugin_configuration.php [iso-8859-1] (original) +++ trunk/Webdav/src/plugin_configuration.php [iso-8859-1] Mon Nov 26 12:34:01 2007 @@ -6,6 +6,8 @@ * @version //autogentag// * @copyright Copyright (C) 2005-2007 eZ systems as. All rights reserved. * @license http://ez.no/licenses/new_bsd New BSD License + * + * @access private */ /** * Base class for plugin configurations. @@ -21,6 +23,8 @@ * @version //autogen// * @copyright Copyright (C) 2005-2007 eZ systems as. All rights reserved. * @license http://ez.no/licenses/new_bsd New BSD License + * + * @access private */ abstract class ezcWebdavPluginConfiguration { Modified: trunk/Webdav/src/plugin_parameters.php ============================================================================== --- trunk/Webdav/src/plugin_parameters.php [iso-8859-1] (original) +++ trunk/Webdav/src/plugin_parameters.php [iso-8859-1] Mon Nov 26 12:34:01 2007 @@ -6,6 +6,8 @@ * @version //autogen// * @copyright Copyright (C) 2005-2007 eZ systems as. All rights reserved. * @license http://ez.no/licenses/new_bsd New BSD License + * + * @access private */ /** * Storage class submitted to callbacks assigned to plugin hooks. @@ -18,6 +20,8 @@ * @version //autogen// * @copyright Copyright (C) 2005-2007 eZ systems as. All rights reserved. * @license http://ez.no/licenses/new_bsd New BSD License + * + * @access private */ class ezcWebdavPluginParameters extends ArrayObject { Modified: trunk/Webdav/src/plugin_registry.php ============================================================================== --- trunk/Webdav/src/plugin_registry.php [iso-8859-1] (original) +++ trunk/Webdav/src/plugin_registry.php [iso-8859-1] Mon Nov 26 12:34:01 2007 @@ -6,6 +6,8 @@ * @version //autogen// * @copyright Copyright (C) 2005-2007 eZ systems as. All rights reserved. * @license http://ez.no/licenses/new_bsd New BSD License + * + * @access private */ /** * Global plugin registry class. @@ -27,6 +29,8 @@ * @version //autogen// * @copyright Copyright (C) 2005-2007 eZ systems as. All rights reserved. * @license http://ez.no/licenses/new_bsd New BSD License + * + * @access private */ class ezcWebdavPluginRegistry { Added: trunk/Webdav/tests/plugin_hooks_test.php ============================================================================== --- trunk/Webdav/tests/plugin_hooks_test.php (added) +++ trunk/Webdav/tests/plugin_hooks_test.php [iso-8859-1] Mon Nov 26 12:34:01 2007 @@ -1,0 +1,108 @@ +<?php + +libxml_use_internal_errors( true ); + +/** + * Reqiuire base test + */ +require_once 'test_case.php'; + +/** + * Tests for ezcWebdavTransport class. + * + * @package Webdav + * @subpackage Tests + */ +class ezcWebdavPluginTest +{ + protected $hooks; + + public static function suite() + { + return new PHPUnit_Framework_TestSuite( __CLASS__ ); + } + + public function __construct() + { + $this->hooks = array ( + 'ezcWebdavTransport' => array ( + 'beforeParseCopyRequest' => true, + 'afterParseCopyRequest' => true, + 'beforeParseDeleteRequest' => true, + 'afterParseDeleteRequest' => true, + 'beforeParseGetRequest' => true, + 'afterParseGetRequest' => true, + 'beforeParseHeadRequest' => true, + 'afterParseHeadRequest' => true, + 'beforeParseMakeCollectionRequest' => true, + 'afterParseMakeCollectionRequest' => true, + 'beforeParseMoveRequest' => true, + 'afterParseMoveRequest' => true, + 'beforeParseOptionsRequest' => true, + 'afterParseOptionsRequest' => true, + 'beforeParsePropFindRequest' => true, + 'afterParsePropFindRequest' => true, + 'beforeParsePropPatchRequest' => true, + 'afterParsePropPatchRequest' => true, + 'beforeParsePutRequest' => true, + 'afterParsePutRequest' => true, + 'beforeProcessCopyResponse' => true, + 'afterProcessCopyResponse' => true, + 'beforeProcessDeleteResponse' => true, + 'afterProcessDeleteResponse' => true, + 'beforeProcessErrorResponse' => true, + 'afterProcessErrorResponse' => true, + 'beforeProcessGetCollectionResponse' => true, + 'afterProcessGetCollectionResponse' => true, + 'beforeProcessGetResourceResponse' => true, + 'afterProcessGetResourceResponse' => true, + 'beforeProcessHeadResponse' => true, + 'afterProcessHeadResponse' => true, + 'beforeProcessMakeCollectionResponse' => true, + 'afterProcessMakeCollectionResponse' => true, + 'beforeProcessMoveResponse' => true, + 'afterProcessMoveResponse' => true, + 'beforeProcessMultiStatusResponse' => true, + 'afterProcessMultiStatusResponse' => true, + 'beforeProcessOptionsResponse' => true, + 'afterProcessOptionsResponse' => true, + 'beforeProcessPropFindResponse' => true, + 'afterProcessPropFindResponse' => true, + 'beforeProcessPropPatchResponse' => true, + 'afterProcessPropPatchResponse' => true, + 'beforeProcessPutResponse' => true, + 'afterProcessPutResponse' => true, + 'parseUnknownRequest' => true, + 'handleUnknownResponse' => true, + 'beforeExtractLiveProperty' => true, + 'afterExtractLiveProperty' => true, + 'beforeExtractDeadProperty' => true, + 'afterExtractDeadProperty' => true, + 'beforeSerializeLiveProperty' => true, + 'afterSerializeLiveProperty' => true, + 'beforeSerializeDeadProperty' => true, + 'afterSerializeDeadProperty' => true, + 'extractUnknownLiveProperty' => true, + 'serializeUnknownLiveProperty' => true, + ), + 'ezcWebdavServer' => array ( + 'receivedRequest' => true, + 'generatedResponse' => true, + ), + ); + } + + public function __call( $method, $parameters ) + { + if ( strpos( $method, 'ezcWebdavTransport' ) === 0 ) + { + + } + else + { + + } + } +} + +?> Propchange: trunk/Webdav/tests/plugin_hooks_test.php ------------------------------------------------------------------------------ svn:eol-style = native -- svn-components mailing list svn-components@lists.ez.no http://lists.ez.no/mailman/listinfo/svn-components