示例#1
0
 /**
  * Sets up the fixture, for example, opens a network connection.
  * This method is called before a test is executed.
  *
  * @return void
  */
 protected function setUp()
 {
     include_once JPATH_BASE . '/libraries/joomla/database/table.php';
     include_once JPATH_BASE . '/libraries/joomla/user/user.php';
     parent::setUp();
     parent::setUpBeforeClass();
     $this->saveFactoryState();
     JUser::getTable('user', 'JTable');
     $this->object = new JUser(42);
     $params = new JRegistry();
     $this->object->setParameters($params);
 }