Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Move more CMS specific classes to legacy. #1152

Merged
merged 2 commits into from

3 participants

@realityking
Collaborator

Move JFormFieldContentLanguage, JHtmlCategory, JHtmlContentLanguage and JHtmlMenu to legacy.

@eddieajau

2 unit test failures.

@LouisLandry LouisLandry merged commit dca41d1 into joomla:staging
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
3  libraries/import.legacy.php
@@ -54,6 +54,9 @@ class_exists('JLoader') or die;
JLoader::register('JText', JPATH_PLATFORM . '/joomla/language/text.php');
JLoader::register('JRoute', JPATH_PLATFORM . '/joomla/application/route.php');
+// Register the folder for the moved JHtml classes
+JHtml::addIncludePath(JPATH_PLATFORM . '/legacy/html');
+
// Register classes where the names have been changed to fit the autoloader rules
// @deprecated 12.3
JLoader::register('JDatabaseQueryMySQL', JPATH_PLATFORM . '/joomla/database/query/mysql.php');
View
0  ...es/joomla/form/fields/contentlanguage.php → ...ies/legacy/form/field/contentlanguage.php
File renamed without changes
View
0  libraries/joomla/html/html/batch.php → libraries/legacy/html/batch.php
File renamed without changes
View
0  libraries/joomla/html/html/category.php → libraries/legacy/html/category.php
File renamed without changes
View
0  ...ries/joomla/html/html/contentlanguage.php → libraries/legacy/html/contentlanguage.php
File renamed without changes
View
0  libraries/joomla/html/html/menu.php → libraries/legacy/html/menu.php
File renamed without changes
View
0  tests/suites/unit/legacy/base/JNodeTest.php → tests/suites/legacy/base/JNodeTest.php
File renamed without changes
View
0  tests/suites/unit/legacy/base/JTreeTest.php → tests/suites/legacy/base/JTreeTest.php
File renamed without changes
View
7 .../fields/JFormFieldContentLanguageTest.php → ...m/field/JFormFieldContentLanguageTest.php
@@ -25,8 +25,8 @@ class JFormFieldContentLanguageTest extends TestCaseDatabase
*/
protected function setUp()
{
- require_once JPATH_PLATFORM . '/joomla/form/fields/contentlanguage.php';
- include_once dirname(__DIR__) . '/inspectors.php';
+ require_once JPATH_PLATFORM . '/legacy/form/field/contentlanguage.php';
+ require_once JPATH_TESTS . '/suites/unit/joomla/form/inspectors.php';
}
/**
@@ -38,7 +38,7 @@ protected function setUp()
*/
protected function getDataSet()
{
- return $this->createXMLDataSet(__DIR__ . '/testfiles/JFormField.xml');
+ return $this->createXMLDataSet(JPATH_TESTS . '/suites/unit/joomla/form/fields/testfiles/JFormField.xml');
}
/**
@@ -47,6 +47,7 @@ protected function getDataSet()
* @return void
*
* @since 11.1
+ * @covers JFormFieldContentLanguage::getOptions
*/
public function testGetInput()
{
View
8 .../unit/joomla/html/html/JHtmlBatchTest.php → tests/suites/legacy/html/JHtmlBatchTest.php
@@ -7,7 +7,7 @@
* @license GNU General Public License version 2 or later; see LICENSE
*/
-require_once JPATH_PLATFORM.'/joomla/html/html/batch.php';
+require_once JPATH_PLATFORM . '/legacy/html/batch.php';
/**
* Test class for JHtmlBatch.
@@ -44,7 +44,7 @@ protected function setUp()
*/
protected function getDataSet()
{
- return $this->createXMLDataSet(__DIR__.'/testfiles/JHtmlTest.xml');
+ return $this->createXMLDataSet(JPATH_TESTS . '/suites/unit/joomla/html/html/testfiles/JHtmlTest.xml');
}
/**
@@ -53,6 +53,7 @@ protected function getDataSet()
* @return void
*
* @since 11.3
+ * @covers JHtmlBatch::access
*/
public function testAccess()
{
@@ -68,6 +69,7 @@ public function testAccess()
* @return void
*
* @since 11.3
+ * @covers JHtmlBatch::item
*/
public function testItem()
{
@@ -83,6 +85,7 @@ public function testItem()
* @return void
*
* @since 11.3
+ * @covers JHtmlBatch::language
*/
public function testLanguage()
{
@@ -98,6 +101,7 @@ public function testLanguage()
* @return void
*
* @since 11.4
+ * @covers JHtmlBatch::user
*/
public function testUser()
{
View
2  ...it/joomla/html/html/JHtmlCategoryTest.php → .../suites/legacy/html/JHtmlCategoryTest.php
@@ -7,7 +7,7 @@
* @license GNU General Public License version 2 or later; see LICENSE
*/
-require_once JPATH_PLATFORM.'/joomla/html/html/category.php';
+require_once JPATH_PLATFORM . '/legacy/html/category.php';
/**
* Test class for JHtmlCategory.
View
6 ...s/unit/joomla/html/html/JHtmlMenuTest.php → tests/suites/legacy/html/JHtmlMenuTest.php
@@ -7,7 +7,7 @@
* @license GNU General Public License version 2 or later; see LICENSE
*/
-require_once JPATH_PLATFORM.'/joomla/html/html/menu.php';
+require_once JPATH_PLATFORM . '/legacy/html/menu.php';
/**
* Test class for JHtmlMenu.
@@ -46,7 +46,7 @@ protected function setUp()
*/
protected function getDataSet()
{
- return $this->createXMLDataSet(__DIR__.'/testfiles/JHtmlTest.xml');
+ return $this->createXMLDataSet(JPATH_TESTS . '/suites/unit/joomla/html/html/testfiles/JHtmlTest.xml');
}
/**
@@ -55,6 +55,7 @@ protected function getDataSet()
* @return void
*
* @since 11.3
+ * @covers JHtmlMenu::menus
*/
public function testMenus()
{
@@ -70,6 +71,7 @@ public function testMenus()
* @return void
*
* @since 11.3
+ * @covers JHtmlMenu::menuitems
*/
public function testMenuitems()
{
Something went wrong with that request. Please try again.