\JLoaderTest
Test class for JLoader.
Synopsis
class JLoaderTest
extends PHPUnit_Framework_TestCase
{
- // members
- protected $cache;
- protected $object;
- protected $bogusPath;
- protected $bogusFullPath;
- // methods
- public static void setUpBeforeClass()
- public static void tearDownAfterClass()
- public array casesImport()
- public array casesJimport()
- public void testDiscover()
- public void testGetClassList()
- public void testLoad()
- public void testImport()
- public void testJimport()
- public void testRegister()
- public void testRegisterNamespace()
- public void testRegisterNamespaceResetPath()
- public void testRegisterNamespaceException()
- public void testRegisterPrefix()
- public void testRegisterAlias()
- public void testRegisterPrefixException()
- public void testSetupDefaultParameters()
- public void testSetupWithoutClasses()
- public void testSetupWithoutPrefixes()
- public void testSetupPsr0()
- protected void unregisterLoaders()
- protected void setUp()
Hierarchy
Extends
Members
protected
- $bogusFullPath
—
string
The full path (including filename) to the bogus object. - $bogusPath
—
string
The path to the bogus object for loader testing. - $cache
—
array
Container for JLoader static values during tests. - $object
—
JLoader is an abstract class of static functions and variables, so will test without instantiation
Methods
protected
- setUp() — Sets up the fixture.
- unregisterLoaders() — A function to unregister the Joomla auto loaders.
public
- casesImport() — The test cases for importing classes
- casesJimport() — The test cases for jimport-ing classes
- setUpBeforeClass() — Cache the JLoader settings while we are resetting things for testing.
- tearDownAfterClass() — Restore the JLoader cache settings after testing the class.
- testDiscover() — Tests the JLoader::discover method.
- testGetClassList() — Tests the JLoader::getClassList method.
- testImport() — The success of this test depends on some files being in the file system to be imported. If the FS changes, this test may need revisited.
- testJimport() — This tests the convenience function jimport.
- testLoad() — Tests the JLoader::load method.
- testRegister() — Tests the JLoader::register method.
- testRegisterAlias() — Tests the JLoader::registerAlias method.
- testRegisterNamespace() — Tests the JLoader::registerNamespace method.
- testRegisterNamespaceException() — Tests the exception thrown by the JLoader::registerNamespace method.
- testRegisterNamespaceResetPath() — Tests the JLoader::registerNamespace method when reseting the paths.
- testRegisterPrefix() — Tests the JLoader::registerPrefix method.
- testRegisterPrefixException() — Tests the exception thrown by the JLoader::registerPrefix method.
- testSetupDefaultParameters() — Tests the JLoader::setup method with the default parameters.
- testSetupPsr0() — Tests the JLoader::setup method.
- testSetupWithoutClasses() — Tests the JLoader::setup method with $enableClasses = false.
- testSetupWithoutPrefixes() — Tests the JLoader::setup method with $enablePrefixes = false.