Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Fix failing unit tests + legacy clean up #1144

Merged
merged 3 commits into from

2 participants

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
View
8 libraries/legacy/application/helper.php
@@ -24,14 +24,6 @@ class JApplicationHelper
* @var array
* @since 11.1
*/
- protected static $clients = null;
-
- /**
- * Client information array
- *
- * @var array
- * @since 11.1
- */
protected static $_clients = null;
/**
View
12 libraries/legacy/pathway/pathway.php
@@ -23,12 +23,6 @@ class JPathway extends JObject
/**
* @var array Array to hold the pathway item objects
* @since 11.1
- */
- protected $pathway = array();
-
- /**
- * @var array Array to hold the pathway item objects
- * @since 11.1
* @deprecated use $pathway declare as private
*/
protected $_pathway = array();
@@ -36,12 +30,6 @@ class JPathway extends JObject
/**
* @var integer Integer number of items in the pathway
* @since 11.1
- */
- protected $count = 0;
-
- /**
- * @var integer Integer number of items in the pathway
- * @since 11.1
* @deprecated use $count declare as private
*/
protected $_count = 0;
View
6 libraries/legacy/view/view.php
@@ -446,7 +446,7 @@ public function getLayoutTemplate()
*/
public function getName()
{
- if (empty($this->name))
+ if (empty($this->_name))
{
$r = null;
if (!preg_match('/View((view)*(.*(view)?.*))$/i', get_class($this), $r))
@@ -457,10 +457,10 @@ public function getName()
{
JLog::add(JText::_('JLIB_APPLICATION_ERROR_VIEW_GET_NAME_SUBSTRING'), JLog::WARNING, 'jerror');
}
- $this->name = strtolower($r[3]);
+ $this->_name = strtolower($r[3]);
}
- return $this->name;
+ return $this->_name;
}
/**
View
1  tests/suites/legacy/controller/JControllerFormTest.php
@@ -20,6 +20,7 @@ class JControllerFormTest extends PHPUnit_Framework_TestCase
* @return void
*
* @since 11.1
+ * @covers JControllerForm::__construct
*/
public function testConstructor()
{
View
20 tests/suites/legacy/controller/JControllerTest.php
@@ -39,6 +39,8 @@ protected function setUp()
* Test JController::addModelPath
*
* @since 11.3
+ *
+ * @covers JController::addModelPath
*/
public function testAddModelPath()
{
@@ -54,6 +56,8 @@ public function testAddModelPath()
/**
* Test JController::createFileName().
+ *
+ * @covers JController::createFileName
*/
public function testCreateFileName()
{
@@ -100,6 +104,8 @@ public function testGetInstance()
* Test JController::__construct
*
* @since 11.3
+ *
+ * @covers JController::__construct
*/
public function test__construct()
{
@@ -118,6 +124,8 @@ public function test__construct()
* If execution halts for some reason, a bad path could be the culprit.
*
* @since 11.3
+ *
+ * @covers JController::addPath
*/
public function testAddPath()
{
@@ -138,6 +146,8 @@ public function testAddPath()
/**
* Test JController::addViewPath
+ *
+ * @covers JController::addViewPath
*/
public function testAddViewPath()
{
@@ -228,6 +238,8 @@ public function testGetModel()
/**
* Test JController::getName
+ *
+ * @covers JController::getName
*/
public function testGetName()
{
@@ -244,6 +256,8 @@ public function testGetName()
* @return void
*
* @since 11.3
+ *
+ * @covers JController::getTask
*/
public function testGetTask()
{
@@ -254,6 +268,8 @@ public function testGetTask()
/**
* Test JController::getTasks
+ *
+ * @covers JController::getTasks
*/
public function testGetTasks()
{
@@ -337,6 +353,8 @@ public function testSetAccessControl()
/**
* Test JController::setMessage
+ *
+ * @covers JController::setMessage
*/
public function testSetMessage()
{
@@ -362,6 +380,8 @@ public function testSetPath()
/**
* Test JController::setRedirect
+ *
+ * @covers JController::setRedirect
*/
public function testSetRedirect()
{
View
38 tests/suites/legacy/view/JViewTest.php
@@ -86,7 +86,8 @@ public function testEscape()
/**
* Test JView::get()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::get
*/
public function testGet()
{
@@ -106,7 +107,8 @@ public function testGet()
/**
* Test JView::getLayout()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::getLayout
*/
public function testGetLayout()
{
@@ -120,7 +122,8 @@ public function testGetLayout()
/**
* Test JView::getModel()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::getModel
*/
public function testGetModel()
{
@@ -152,7 +155,8 @@ public function testGetModel()
/**
* Test JView::getLayoutTemplate()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::getLayoutTemplate
*/
public function testGetLayoutTemplate()
{
@@ -166,13 +170,14 @@ public function testGetLayoutTemplate()
/**
* Test JView::getName()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::getName
*/
public function testGetName()
{
$this->assertEquals('', $this->class->getName());
- TestReflection::setValue($this->class, 'name', 'inspector2');
+ TestReflection::setValue($this->class, '_name', 'inspector2');
$this->assertEquals('inspector2', $this->class->getName());
}
@@ -180,7 +185,8 @@ public function testGetName()
/**
* Test JView::setModel()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::setModel
*/
public function testSetModel()
{
@@ -222,7 +228,8 @@ public function testSetModel()
/**
* Test JView::setLayout()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::setLayout
*/
public function testSetLayout()
{
@@ -242,7 +249,8 @@ public function testSetLayout()
/**
* Test JView::setLayoutExt()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::setLayoutExt
*/
public function testSetLayoutExt()
{
@@ -256,7 +264,8 @@ public function testSetLayoutExt()
/**
* Test JView::setEscape()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::setEscape
*/
public function testSetEscape()
{
@@ -274,7 +283,8 @@ public function testSetEscape()
/**
* Test JView::addTemplatePath()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::addTemplatePath
*/
public function testAddTemplatePath()
{
@@ -303,7 +313,8 @@ public function testAddTemplatePath()
/**
* Test JView::addHelperPath()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::addHelperPath
*/
public function testAddHelperPath()
{
@@ -359,7 +370,8 @@ public function test_setPath()
/**
* Test JView::_addPath()
*
- * @since 11.3
+ * @since 11.3
+ * @covers JView::_addPath
*/
public function test_addPath()
{
Something went wrong with that request. Please try again.