From 2005cca77ff4047f16dc490a9df633b8e3fd8bcf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maur=C3=ADcio=20Meneghini=20Fauth?= Date: Wed, 30 May 2018 21:02:26 -0300 Subject: [PATCH] Fix methods and properties visibility issues MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: MaurĂ­cio Meneghini Fauth --- .../Server/ServerCollationsController.php | 2 +- .../Server/ServerDatabasesController.php | 2 +- .../Table/TableSearchController.php | 2 +- libraries/classes/DatabaseInterface.php | 2 +- libraries/classes/Dbi/DbiDummy.php | 2 +- libraries/classes/Display/Results.php | 76 +++++----- libraries/classes/Index.php | 10 +- libraries/classes/Navigation/Nodes/Node.php | 4 +- libraries/classes/OpenDocument.php | 2 +- libraries/classes/Pdf.php | 6 +- .../classes/Plugins/Export/Helpers/Pdf.php | 4 +- libraries/classes/Plugins/Schema/Pdf/Pdf.php | 18 +-- .../classes/Plugins/Schema/RelationStats.php | 6 +- .../Plugins/Schema/Svg/SvgRelationSchema.php | 4 +- .../classes/Plugins/Schema/TableStats.php | 3 +- libraries/classes/Response.php | 11 +- libraries/classes/StorageEngine.php | 8 +- libraries/classes/SysInfo.php | 2 +- libraries/classes/SysInfoLinux.php | 4 +- libraries/classes/SysInfoWINNT.php | 4 +- libraries/classes/SystemDatabase.php | 4 +- libraries/classes/Table.php | 20 +-- libraries/classes/Template.php | 2 +- libraries/classes/Theme.php | 20 +-- libraries/classes/ThemeManager.php | 14 +- libraries/classes/Util.php | 2 +- test/classes/AdvisorTest.php | 2 +- test/classes/BookmarkTest.php | 2 +- test/classes/BrowseForeignersTest.php | 8 +- test/classes/CentralColumnsTest.php | 4 +- test/classes/CharsetsTest.php | 2 +- test/classes/Config/ConfigFileTest.php | 2 +- test/classes/Config/DescriptionTest.php | 2 +- .../Config/FormDisplayTemplateTest.php | 2 +- test/classes/Config/FormDisplayTest.php | 2 +- test/classes/Config/FormTest.php | 2 +- test/classes/Config/Forms/FormListTest.php | 2 +- test/classes/Config/PageSettingsTest.php | 4 +- .../classes/Config/ServerConfigChecksTest.php | 2 +- .../DatabaseStructureControllerTest.php | 2 +- .../Server/ServerBinlogControllerTest.php | 2 +- .../Server/ServerCollationsControllerTest.php | 2 +- .../Server/ServerDatabasesControllerTest.php | 2 +- .../Server/ServerEnginesControllerTest.php | 2 +- .../Server/ServerPluginsControllerTest.php | 2 +- .../Server/ServerVariablesControllerTest.php | 2 +- .../Table/TableStructureControllerTest.php | 2 +- test/classes/CoreTest.php | 26 ++-- test/classes/Display/ChangePasswordTest.php | 2 +- test/classes/Display/CreateTableTest.php | 2 +- test/classes/Display/ExportTest.php | 2 +- test/classes/EncodingTest.php | 2 +- test/classes/FileTest.php | 2 +- test/classes/FontTest.php | 8 +- test/classes/HeaderTest.php | 2 +- test/classes/ImportTest.php | 36 ++--- test/classes/IndexTest.php | 2 +- test/classes/InsertEditTest.php | 2 +- test/classes/LanguageTest.php | 2 +- test/classes/ListDatabaseTest.php | 2 +- test/classes/MenuTest.php | 12 +- test/classes/Navigation/NodeFactoryTest.php | 2 +- .../Nodes/NodeColumnContainerTest.php | 2 +- .../Navigation/Nodes/NodeColumnTest.php | 2 +- .../Navigation/Nodes/NodeDatabaseTest.php | 2 +- .../Nodes/NodeEventContainerTest.php | 2 +- .../Navigation/Nodes/NodeEventTest.php | 2 +- .../Nodes/NodeFunctionContainerTest.php | 2 +- .../Navigation/Nodes/NodeFunctionTest.php | 2 +- .../Nodes/NodeIndexContainerTest.php | 2 +- .../Navigation/Nodes/NodeIndexTest.php | 2 +- .../Nodes/NodeProcedureContainerTest.php | 2 +- .../Navigation/Nodes/NodeProcedureTest.php | 2 +- .../Nodes/NodeTableContainerTest.php | 2 +- .../Navigation/Nodes/NodeTableTest.php | 2 +- test/classes/Navigation/Nodes/NodeTest.php | 2 +- .../Nodes/NodeTriggerContainerTest.php | 2 +- .../Navigation/Nodes/NodeTriggerTest.php | 2 +- .../Nodes/NodeViewContainerTest.php | 2 +- .../classes/Navigation/Nodes/NodeViewTest.php | 2 +- test/classes/NormalizationTest.php | 2 +- test/classes/PdfTest.php | 2 +- .../Plugins/Export/ExportCodegenTest.php | 7 +- test/classes/Plugins/Export/ExportCsvTest.php | 2 +- .../Plugins/Export/ExportExcelTest.php | 2 +- .../Plugins/Export/ExportHtmlwordTest.php | 2 +- .../classes/Plugins/Export/ExportJsonTest.php | 2 +- .../Plugins/Export/ExportLatexTest.php | 2 +- .../Plugins/Export/ExportMediawikiTest.php | 2 +- test/classes/Plugins/Export/ExportOdsTest.php | 2 +- test/classes/Plugins/Export/ExportOdtTest.php | 2 +- test/classes/Plugins/Export/ExportPdfTest.php | 2 +- .../Plugins/Export/ExportPhparrayTest.php | 2 +- test/classes/Plugins/Export/ExportSqlTest.php | 2 +- .../Plugins/Export/ExportTexytextTest.php | 2 +- test/classes/Plugins/Export/ExportXmlTest.php | 2 +- .../classes/Plugins/Export/ExportYamlTest.php | 2 +- .../Export/Helpers/TablePropertyTest.php | 2 +- .../Groups/OptionsPropertyMainGroupTest.php | 2 +- .../Groups/OptionsPropertyRootGroupTest.php | 2 +- .../Groups/OptionsPropertySubgroupTest.php | 2 +- .../Options/OptionsPropertyGroupTest.php | 2 +- .../Options/OptionsPropertyItemTest.php | 2 +- .../Options/OptionsPropertyOneItemTest.php | 2 +- .../Plugins/ExportPluginPropertiesTest.php | 2 +- .../Plugins/ImportPluginPropertiesTest.php | 2 +- .../Plugins/PluginPropertyItemTest.php | 2 +- test/classes/Properties/PropertyItemTest.php | 2 +- test/classes/RelationCleanupDbiMock.php | 10 +- test/classes/RelationCleanupTest.php | 2 +- test/classes/ReplicationGuiTest.php | 2 +- test/classes/Server/PrivilegesTest.php | 18 +-- test/classes/Server/SelectTest.php | 2 +- test/classes/Server/Status/AdvisorTest.php | 2 +- test/classes/Server/Status/DataTest.php | 5 +- test/classes/Server/Status/ProcessesTest.php | 2 +- test/classes/Server/Status/QueriesTest.php | 2 +- test/classes/Server/Status/VariablesTest.php | 2 +- test/classes/Server/StatusTest.php | 2 +- test/classes/Server/UserGroupsTest.php | 2 +- test/classes/Setup/FormProcessingTest.php | 2 +- test/classes/Setup/IndexTest.php | 2 +- test/classes/ThemeManagerTest.php | 2 +- test/classes/TransformationsTest.php | 2 +- test/classes/TwoFactorTest.php | 2 +- test/classes/UrlTest.php | 2 +- test/classes/UtilTest.php | 130 +++++++++--------- test/libraries/common/GetCheckboxTest.php | 8 +- test/selenium/CreateDropDatabaseTest.php | 2 +- test/selenium/CreateRemoveUserTest.php | 2 +- test/selenium/DbEventsTest.php | 2 +- test/selenium/DbProceduresTest.php | 2 +- test/selenium/DbStructureTest.php | 2 +- test/selenium/DbTriggersTest.php | 2 +- test/selenium/ExportTest.php | 2 +- test/selenium/NormalizationTest.php | 2 +- test/selenium/QueryByExampleTest.php | 2 +- test/selenium/SqlQueryTest.php | 2 +- test/selenium/TableBrowseTest.php | 2 +- test/selenium/TableInsertTest.php | 2 +- test/selenium/TableOperationsTest.php | 2 +- test/selenium/TableStructureTest.php | 2 +- test/selenium/TrackingTest.php | 2 +- 143 files changed, 362 insertions(+), 356 deletions(-) diff --git a/libraries/classes/Controllers/Server/ServerCollationsController.php b/libraries/classes/Controllers/Server/ServerCollationsController.php index f7fdd0dbcc..bd33eecc15 100644 --- a/libraries/classes/Controllers/Server/ServerCollationsController.php +++ b/libraries/classes/Controllers/Server/ServerCollationsController.php @@ -61,7 +61,7 @@ class ServerCollationsController extends Controller * * @return string */ - function _getHtmlForCharsets( + public function _getHtmlForCharsets( array $mysqlCharsets, array $mysqlCollations, array $mysqlCharsetsDesc, diff --git a/libraries/classes/Controllers/Server/ServerDatabasesController.php b/libraries/classes/Controllers/Server/ServerDatabasesController.php index 7136ab001a..dd24b5fc30 100644 --- a/libraries/classes/Controllers/Server/ServerDatabasesController.php +++ b/libraries/classes/Controllers/Server/ServerDatabasesController.php @@ -432,7 +432,7 @@ class ServerDatabasesController extends Controller * * @return string $column_order, $out */ - function _buildHtmlForDb( + public function _buildHtmlForDb( array $current, array $column_order, array $replication_types, diff --git a/libraries/classes/Controllers/Table/TableSearchController.php b/libraries/classes/Controllers/Table/TableSearchController.php index df28512e61..18c2f6ec0a 100644 --- a/libraries/classes/Controllers/Table/TableSearchController.php +++ b/libraries/classes/Controllers/Table/TableSearchController.php @@ -643,7 +643,7 @@ class TableSearchController extends TableController * * @return string HTML for previewing strings found and their replacements */ - function getReplacePreview( + public function getReplacePreview( $columnIndex, $find, $replaceWith, diff --git a/libraries/classes/DatabaseInterface.php b/libraries/classes/DatabaseInterface.php index c23e9f6a63..e0e2f1d46c 100644 --- a/libraries/classes/DatabaseInterface.php +++ b/libraries/classes/DatabaseInterface.php @@ -3015,7 +3015,7 @@ class DatabaseInterface * * @return string $server_collation */ - function getServerCollation(): string + public function getServerCollation(): string { return $this->fetchValue('SELECT @@collation_server'); } diff --git a/libraries/classes/Dbi/DbiDummy.php b/libraries/classes/Dbi/DbiDummy.php index 33621bf8e5..3741e1f1e5 100644 --- a/libraries/classes/Dbi/DbiDummy.php +++ b/libraries/classes/Dbi/DbiDummy.php @@ -34,7 +34,7 @@ class DbiDummy implements DbiExtension /** * @var int */ - const OFFSET_GLOBAL = 1000; + public const OFFSET_GLOBAL = 1000; /** * DbiDummy constructor. diff --git a/libraries/classes/Display/Results.php b/libraries/classes/Display/Results.php index 54842528d2..ed4a946b3a 100644 --- a/libraries/classes/Display/Results.php +++ b/libraries/classes/Display/Results.php @@ -35,55 +35,55 @@ use PhpMyAdmin\Util; class Results { // Define constants - const NO_EDIT_OR_DELETE = 'nn'; - const UPDATE_ROW = 'ur'; - const DELETE_ROW = 'dr'; - const KILL_PROCESS = 'kp'; + public const NO_EDIT_OR_DELETE = 'nn'; + public const UPDATE_ROW = 'ur'; + public const DELETE_ROW = 'dr'; + public const KILL_PROCESS = 'kp'; - const POSITION_LEFT = 'left'; - const POSITION_RIGHT = 'right'; - const POSITION_BOTH = 'both'; - const POSITION_NONE = 'none'; + public const POSITION_LEFT = 'left'; + public const POSITION_RIGHT = 'right'; + public const POSITION_BOTH = 'both'; + public const POSITION_NONE = 'none'; - const PLACE_TOP_DIRECTION_DROPDOWN = 'top_direction_dropdown'; - const PLACE_BOTTOM_DIRECTION_DROPDOWN = 'bottom_direction_dropdown'; + public const PLACE_TOP_DIRECTION_DROPDOWN = 'top_direction_dropdown'; + public const PLACE_BOTTOM_DIRECTION_DROPDOWN = 'bottom_direction_dropdown'; - const DISPLAY_FULL_TEXT = 'F'; - const DISPLAY_PARTIAL_TEXT = 'P'; + public const DISPLAY_FULL_TEXT = 'F'; + public const DISPLAY_PARTIAL_TEXT = 'P'; - const HEADER_FLIP_TYPE_AUTO = 'auto'; - const HEADER_FLIP_TYPE_CSS = 'css'; - const HEADER_FLIP_TYPE_FAKE = 'fake'; + public const HEADER_FLIP_TYPE_AUTO = 'auto'; + public const HEADER_FLIP_TYPE_CSS = 'css'; + public const HEADER_FLIP_TYPE_FAKE = 'fake'; - const DATE_FIELD = 'date'; - const DATETIME_FIELD = 'datetime'; - const TIMESTAMP_FIELD = 'timestamp'; - const TIME_FIELD = 'time'; - const STRING_FIELD = 'string'; - const GEOMETRY_FIELD = 'geometry'; - const BLOB_FIELD = 'BLOB'; - const BINARY_FIELD = 'BINARY'; + public const DATE_FIELD = 'date'; + public const DATETIME_FIELD = 'datetime'; + public const TIMESTAMP_FIELD = 'timestamp'; + public const TIME_FIELD = 'time'; + public const STRING_FIELD = 'string'; + public const GEOMETRY_FIELD = 'geometry'; + public const BLOB_FIELD = 'BLOB'; + public const BINARY_FIELD = 'BINARY'; - const RELATIONAL_KEY = 'K'; - const RELATIONAL_DISPLAY_COLUMN = 'D'; + public const RELATIONAL_KEY = 'K'; + public const RELATIONAL_DISPLAY_COLUMN = 'D'; - const GEOMETRY_DISP_GEOM = 'GEOM'; - const GEOMETRY_DISP_WKT = 'WKT'; - const GEOMETRY_DISP_WKB = 'WKB'; + public const GEOMETRY_DISP_GEOM = 'GEOM'; + public const GEOMETRY_DISP_WKT = 'WKT'; + public const GEOMETRY_DISP_WKB = 'WKB'; - const SMART_SORT_ORDER = 'SMART'; - const ASCENDING_SORT_DIR = 'ASC'; - const DESCENDING_SORT_DIR = 'DESC'; + public const SMART_SORT_ORDER = 'SMART'; + public const ASCENDING_SORT_DIR = 'ASC'; + public const DESCENDING_SORT_DIR = 'DESC'; - const TABLE_TYPE_INNO_DB = 'InnoDB'; - const ALL_ROWS = 'all'; - const QUERY_TYPE_SELECT = 'SELECT'; + public const TABLE_TYPE_INNO_DB = 'InnoDB'; + public const ALL_ROWS = 'all'; + public const QUERY_TYPE_SELECT = 'SELECT'; - const ROUTINE_PROCEDURE = 'procedure'; - const ROUTINE_FUNCTION = 'function'; + public const ROUTINE_PROCEDURE = 'procedure'; + public const ROUTINE_FUNCTION = 'function'; - const ACTION_LINK_CONTENT_ICONS = 'icons'; - const ACTION_LINK_CONTENT_TEXT = 'text'; + public const ACTION_LINK_CONTENT_ICONS = 'icons'; + public const ACTION_LINK_CONTENT_TEXT = 'text'; // Declare global fields diff --git a/libraries/classes/Index.php b/libraries/classes/Index.php index c9608c5a21..474e6362f9 100644 --- a/libraries/classes/Index.php +++ b/libraries/classes/Index.php @@ -23,11 +23,11 @@ use PhpMyAdmin\Util; */ class Index { - const PRIMARY = 1; - const UNIQUE = 2; - const INDEX = 4; - const SPATIAL = 8; - const FULLTEXT = 16; + public const PRIMARY = 1; + public const UNIQUE = 2; + public const INDEX = 4; + public const SPATIAL = 8; + public const FULLTEXT = 16; /** * Class-wide storage container for indexes (caching, singleton) diff --git a/libraries/classes/Navigation/Nodes/Node.php b/libraries/classes/Navigation/Nodes/Node.php index b3e651261b..0465ecca36 100644 --- a/libraries/classes/Navigation/Nodes/Node.php +++ b/libraries/classes/Navigation/Nodes/Node.php @@ -23,11 +23,11 @@ class Node /** * @var int Defines a possible node type */ - const CONTAINER = 0; + public const CONTAINER = 0; /** * @var int Defines a possible node type */ - const OBJECT = 1; + public const OBJECT = 1; /** * @var string A non-unique identifier for the node * This may be trimmed when grouping nodes diff --git a/libraries/classes/OpenDocument.php b/libraries/classes/OpenDocument.php index c021a0b618..79e036c59c 100644 --- a/libraries/classes/OpenDocument.php +++ b/libraries/classes/OpenDocument.php @@ -19,7 +19,7 @@ use PhpMyAdmin\ZipExtension; class OpenDocument { - const NS = << false, - 'error' => 'JSON encoding failed: ' . $error, - ] - ); + echo json_encode([ + 'success' => false, + 'error' => 'JSON encoding failed: ' . $error, + ]); } else { echo $result; } diff --git a/libraries/classes/StorageEngine.php b/libraries/classes/StorageEngine.php index 0114c4e894..e270920124 100644 --- a/libraries/classes/StorageEngine.php +++ b/libraries/classes/StorageEngine.php @@ -46,23 +46,23 @@ class StorageEngine /** * @var string engine name */ - var $engine = 'dummy'; + public $engine = 'dummy'; /** * @var string engine title/description */ - var $title = 'PMA Dummy Engine Class'; + public $title = 'PMA Dummy Engine Class'; /** * @var string engine lang description */ - var $comment + public $comment = 'If you read this text inside phpMyAdmin, something went wrong...'; /** * @var integer engine supported by current server */ - var $support = PMA_ENGINE_SUPPORT_NO; + public $support = PMA_ENGINE_SUPPORT_NO; /** * Constructor diff --git a/libraries/classes/SysInfo.php b/libraries/classes/SysInfo.php index fa3b40c4dd..7501b059bf 100644 --- a/libraries/classes/SysInfo.php +++ b/libraries/classes/SysInfo.php @@ -22,7 +22,7 @@ use PhpMyAdmin\SysInfoBase; */ class SysInfo { - const MEMORY_REGEXP = '/^(MemTotal|MemFree|Cached|Buffers|SwapCached|SwapTotal|SwapFree):\s+(.*)\s*kB/im'; + public const MEMORY_REGEXP = '/^(MemTotal|MemFree|Cached|Buffers|SwapCached|SwapTotal|SwapFree):\s+(.*)\s*kB/im'; /** * Returns OS type used for sysinfo class diff --git a/libraries/classes/SysInfoLinux.php b/libraries/classes/SysInfoLinux.php index 4f0ced357d..f7ae3e504e 100644 --- a/libraries/classes/SysInfoLinux.php +++ b/libraries/classes/SysInfoLinux.php @@ -26,7 +26,7 @@ class SysInfoLinux extends SysInfoBase * * @return array with load data */ - function loadavg() + public function loadavg() { $buf = file_get_contents('/proc/stat'); $nums = preg_split( @@ -59,7 +59,7 @@ class SysInfoLinux extends SysInfoBase * * @return array with memory usage data */ - function memory() + public function memory() { preg_match_all( SysInfo::MEMORY_REGEXP, diff --git a/libraries/classes/SysInfoWINNT.php b/libraries/classes/SysInfoWINNT.php index c96081ee64..e236773e35 100644 --- a/libraries/classes/SysInfoWINNT.php +++ b/libraries/classes/SysInfoWINNT.php @@ -41,7 +41,7 @@ class SysInfoWINNT extends SysInfoBase * * @return array with load data */ - function loadavg() + public function loadavg() { $loadavg = ""; $sum = 0; @@ -101,7 +101,7 @@ class SysInfoWINNT extends SysInfoBase * * @return array with memory usage data */ - function memory() + public function memory() { $buffer = $this->_getWMI( "Win32_OperatingSystem", diff --git a/libraries/classes/SystemDatabase.php b/libraries/classes/SystemDatabase.php index 1b5df002e0..c476701d98 100644 --- a/libraries/classes/SystemDatabase.php +++ b/libraries/classes/SystemDatabase.php @@ -36,7 +36,7 @@ class SystemDatabase * @param DatabaseInterface $dbi Database interface for the system database * */ - function __construct(DatabaseInterface $dbi) + public function __construct(DatabaseInterface $dbi) { $this->dbi = $dbi; $this->relation = new Relation(); @@ -76,7 +76,7 @@ class SystemDatabase * * @return string $new_transformations_sql SQL query for new transformations */ - function getNewTransformationDataSql( + public function getNewTransformationDataSql( $pma_transformation_data, array $column_map, $view_name, diff --git a/libraries/classes/Table.php b/libraries/classes/Table.php index 60c3fd4559..176d3c8f0d 100644 --- a/libraries/classes/Table.php +++ b/libraries/classes/Table.php @@ -34,34 +34,34 @@ class Table /** * UI preferences properties */ - const PROP_SORTED_COLUMN = 'sorted_col'; - const PROP_COLUMN_ORDER = 'col_order'; - const PROP_COLUMN_VISIB = 'col_visib'; + public const PROP_SORTED_COLUMN = 'sorted_col'; + public const PROP_COLUMN_ORDER = 'col_order'; + public const PROP_COLUMN_VISIB = 'col_visib'; /** * @var string engine (innodb, myisam, bdb, ...) */ - var $engine = ''; + public $engine = ''; /** * @var string type (view, base table, system view) */ - var $type = ''; + public $type = ''; /** * @var array UI preferences */ - var $uiprefs; + public $uiprefs; /** * @var array errors occurred */ - var $errors = []; + public $errors = []; /** * @var array messages */ - var $messages = []; + public $messages = []; /** * @var string table name @@ -482,7 +482,7 @@ class Table * * @return string field specification */ - static function generateFieldSpec( + public static function generateFieldSpec( $name, $type, $length = '', @@ -1451,7 +1451,7 @@ class Table * * @return boolean whether the string is valid or not */ - static function isValidName($table_name, $is_backquoted = false) + public static function isValidName($table_name, $is_backquoted = false) { if ($table_name !== rtrim($table_name)) { // trailing spaces not allowed even in backquotes diff --git a/libraries/classes/Template.php b/libraries/classes/Template.php index a0b622475a..e27dcca62b 100644 --- a/libraries/classes/Template.php +++ b/libraries/classes/Template.php @@ -47,7 +47,7 @@ class Template */ static protected $twig; - const BASE_PATH = 'templates/'; + public const BASE_PATH = 'templates/'; /** * Template constructor diff --git a/libraries/classes/Theme.php b/libraries/classes/Theme.php index 12f8464011..5a096aac1f 100644 --- a/libraries/classes/Theme.php +++ b/libraries/classes/Theme.php @@ -28,37 +28,37 @@ class Theme * @var string theme version * @access protected */ - var $version = '0.0.0.0'; + public $version = '0.0.0.0'; /** * @var string theme name * @access protected */ - var $name = ''; + public $name = ''; /** * @var string theme id * @access protected */ - var $id = ''; + public $id = ''; /** * @var string theme path * @access protected */ - var $path = ''; + public $path = ''; /** * @var string image path * @access protected */ - var $img_path = ''; + public $img_path = ''; /** * @var integer last modification time for info file * @access protected */ - var $mtime_info = 0; + public $mtime_info = 0; /** * needed because sometimes, the mtime for different themes @@ -66,13 +66,13 @@ class Theme * @var integer filesize for info file * @access protected */ - var $filesize_info = 0; + public $filesize_info = 0; /** * @var array List of css files to load * @access private */ - private $_cssFiles = [ + public $_cssFiles = [ 'common', 'enum_editor', 'gis', @@ -91,7 +91,7 @@ class Theme * @return boolean whether loading them info was successful or not * @access public */ - function loadInfo() + public function loadInfo() { $infofile = $this->getPath() . '/theme.json'; if (! @file_exists($infofile)) { @@ -425,7 +425,7 @@ class Theme * * @return string CSS code. */ - function getCssGradient($start_color, $end_color) + public function getCssGradient($start_color, $end_color) { $result = []; // Opera 9.5+, IE 9 diff --git a/libraries/classes/ThemeManager.php b/libraries/classes/ThemeManager.php index 13159b4606..4151558963 100644 --- a/libraries/classes/ThemeManager.php +++ b/libraries/classes/ThemeManager.php @@ -37,37 +37,37 @@ class ThemeManager /** * @var array available themes */ - var $themes = []; + public $themes = []; /** * @var string cookie name */ - var $cookie_name = 'pma_theme'; + public $cookie_name = 'pma_theme'; /** * @var boolean */ - var $per_server = false; + public $per_server = false; /** * @var string name of active theme */ - var $active_theme = ''; + public $active_theme = ''; /** * @var Theme Theme active theme */ - var $theme = null; + public $theme = null; /** * @var string */ - var $theme_default; + public $theme_default; /** * @const string The name of the fallback theme */ - const FALLBACK_THEME = 'pmahomme'; + public const FALLBACK_THEME = 'pmahomme'; /** * Constructor for Theme Manager class diff --git a/libraries/classes/Util.php b/libraries/classes/Util.php index 2e3c234073..396abe442b 100644 --- a/libraries/classes/Util.php +++ b/libraries/classes/Util.php @@ -2077,7 +2077,7 @@ class Util * * @return string */ - static function getCharsetQueryPart($collation, $override = false) + public static function getCharsetQueryPart($collation, $override = false) { list($charset) = explode('_', $collation); $keyword = ' CHARSET='; diff --git a/test/classes/AdvisorTest.php b/test/classes/AdvisorTest.php index 69c2e8b465..377d0dec37 100644 --- a/test/classes/AdvisorTest.php +++ b/test/classes/AdvisorTest.php @@ -28,7 +28,7 @@ class AdvisorTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['PMA_Config'] = new Config(); $GLOBALS['server'] = 1; diff --git a/test/classes/BookmarkTest.php b/test/classes/BookmarkTest.php index 3817728b16..3264c30a50 100644 --- a/test/classes/BookmarkTest.php +++ b/test/classes/BookmarkTest.php @@ -26,7 +26,7 @@ class BookmarkTest extends TestCase * @access protected * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['cfg']['Server']['user'] = 'root'; $GLOBALS['cfg']['Server']['pmadb'] = 'phpmyadmin'; diff --git a/test/classes/BrowseForeignersTest.php b/test/classes/BrowseForeignersTest.php index ba84ddc9c1..81221e7385 100644 --- a/test/classes/BrowseForeignersTest.php +++ b/test/classes/BrowseForeignersTest.php @@ -57,7 +57,7 @@ class BrowseForeignersTest extends TestCase * * @return void */ - function testGetForeignLimit() + public function testGetForeignLimit() { $this->assertNull( $this->browseForeigners->getForeignLimit('Show all') @@ -99,7 +99,7 @@ class BrowseForeignersTest extends TestCase * * @return void */ - function testGetHtmlForGotoPage() + public function testGetHtmlForGotoPage() { $this->assertEquals( '', @@ -160,7 +160,7 @@ class BrowseForeignersTest extends TestCase * * @return void */ - function testGetDescriptionAndTitle() + public function testGetDescriptionAndTitle() { $desc = 'foobarexpects($this->once()) ->method('fetchResult') diff --git a/test/classes/CharsetsTest.php b/test/classes/CharsetsTest.php index e119a24163..046d9e7dc7 100644 --- a/test/classes/CharsetsTest.php +++ b/test/classes/CharsetsTest.php @@ -22,7 +22,7 @@ class CharsetsTest extends TestCase /** * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['cfg']['DBG']['sql'] = false; $GLOBALS['cfg']['Server']['DisableIS'] = false; diff --git a/test/classes/Config/ConfigFileTest.php b/test/classes/Config/ConfigFileTest.php index d1080c1f3d..29f878621f 100644 --- a/test/classes/Config/ConfigFileTest.php +++ b/test/classes/Config/ConfigFileTest.php @@ -24,7 +24,7 @@ class ConfigFileTest extends PmaTestCase * Any valid key that exists in config.default.php and isn't empty * @var string */ - const SIMPLE_KEY_WITH_DEFAULT_VALUE = 'DefaultQueryTable'; + public const SIMPLE_KEY_WITH_DEFAULT_VALUE = 'DefaultQueryTable'; /** * Object under test diff --git a/test/classes/Config/DescriptionTest.php b/test/classes/Config/DescriptionTest.php index c1cd399f0e..bf8b0c333b 100644 --- a/test/classes/Config/DescriptionTest.php +++ b/test/classes/Config/DescriptionTest.php @@ -25,7 +25,7 @@ class DescriptionTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['PMA_Config'] = new Config(); } diff --git a/test/classes/Config/FormDisplayTemplateTest.php b/test/classes/Config/FormDisplayTemplateTest.php index 3c5e4c1fb6..d2f454d500 100644 --- a/test/classes/Config/FormDisplayTemplateTest.php +++ b/test/classes/Config/FormDisplayTemplateTest.php @@ -26,7 +26,7 @@ class FormDisplayTemplateTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['PMA_Config'] = new Config(); } diff --git a/test/classes/Config/FormDisplayTest.php b/test/classes/Config/FormDisplayTest.php index 23aef22489..e6f9ad7b53 100644 --- a/test/classes/Config/FormDisplayTest.php +++ b/test/classes/Config/FormDisplayTest.php @@ -34,7 +34,7 @@ class FormDisplayTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['pmaThemePath'] = $GLOBALS['PMA_Theme']->getPath(); $GLOBALS['PMA_Config'] = new Config(); diff --git a/test/classes/Config/FormTest.php b/test/classes/Config/FormTest.php index c6885f5e9e..76a88bf67d 100644 --- a/test/classes/Config/FormTest.php +++ b/test/classes/Config/FormTest.php @@ -33,7 +33,7 @@ class FormTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['pmaThemePath'] = $GLOBALS['PMA_Theme']->getPath(); $GLOBALS['PMA_Config'] = new Config(); diff --git a/test/classes/Config/Forms/FormListTest.php b/test/classes/Config/Forms/FormListTest.php index c94e46efe2..0e32602d1f 100644 --- a/test/classes/Config/Forms/FormListTest.php +++ b/test/classes/Config/Forms/FormListTest.php @@ -26,7 +26,7 @@ class FormListTest extends PmaTestCase /** * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['PMA_Config'] = new Config(); $GLOBALS['server'] = 1; diff --git a/test/classes/Config/PageSettingsTest.php b/test/classes/Config/PageSettingsTest.php index da847f16c7..43e2ce1890 100644 --- a/test/classes/Config/PageSettingsTest.php +++ b/test/classes/Config/PageSettingsTest.php @@ -25,7 +25,7 @@ class PageSettingsTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['PMA_Config'] = new Config(); $GLOBALS['server'] = 1; @@ -85,7 +85,7 @@ class PageSettingsTest extends PmaTestCase * * @return void */ - function testGetNaviSettings() + public function testGetNaviSettings() { $html = PageSettings::getNaviSettings(); diff --git a/test/classes/Config/ServerConfigChecksTest.php b/test/classes/Config/ServerConfigChecksTest.php index e7f3264de9..f3a42da4e2 100644 --- a/test/classes/Config/ServerConfigChecksTest.php +++ b/test/classes/Config/ServerConfigChecksTest.php @@ -32,7 +32,7 @@ class ServeConfigChecksTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['PMA_Config'] = new Config(); $GLOBALS['cfg']['AvailableCharsets'] = []; diff --git a/test/classes/Controllers/Database/DatabaseStructureControllerTest.php b/test/classes/Controllers/Database/DatabaseStructureControllerTest.php index 2768e17de0..81c9c9880f 100644 --- a/test/classes/Controllers/Database/DatabaseStructureControllerTest.php +++ b/test/classes/Controllers/Database/DatabaseStructureControllerTest.php @@ -37,7 +37,7 @@ class DatabaseStructureControllerTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Controllers/Server/ServerBinlogControllerTest.php b/test/classes/Controllers/Server/ServerBinlogControllerTest.php index ff49199bed..87d20e7b9f 100644 --- a/test/classes/Controllers/Server/ServerBinlogControllerTest.php +++ b/test/classes/Controllers/Server/ServerBinlogControllerTest.php @@ -29,7 +29,7 @@ class ServerBinlogControllerTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Controllers/Server/ServerCollationsControllerTest.php b/test/classes/Controllers/Server/ServerCollationsControllerTest.php index e4a8e4aa2c..eff71bf31e 100644 --- a/test/classes/Controllers/Server/ServerCollationsControllerTest.php +++ b/test/classes/Controllers/Server/ServerCollationsControllerTest.php @@ -29,7 +29,7 @@ class ServerCollationsControllerTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = 'index1'; diff --git a/test/classes/Controllers/Server/ServerDatabasesControllerTest.php b/test/classes/Controllers/Server/ServerDatabasesControllerTest.php index 888d5767c4..8608a8f50c 100644 --- a/test/classes/Controllers/Server/ServerDatabasesControllerTest.php +++ b/test/classes/Controllers/Server/ServerDatabasesControllerTest.php @@ -28,7 +28,7 @@ class ServerDatabasesControllerTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Controllers/Server/ServerEnginesControllerTest.php b/test/classes/Controllers/Server/ServerEnginesControllerTest.php index 57cbb3d17c..03624b6c3a 100644 --- a/test/classes/Controllers/Server/ServerEnginesControllerTest.php +++ b/test/classes/Controllers/Server/ServerEnginesControllerTest.php @@ -36,7 +36,7 @@ class ServerEnginesControllerTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Controllers/Server/ServerPluginsControllerTest.php b/test/classes/Controllers/Server/ServerPluginsControllerTest.php index cfe0b2f83c..225166dee4 100644 --- a/test/classes/Controllers/Server/ServerPluginsControllerTest.php +++ b/test/classes/Controllers/Server/ServerPluginsControllerTest.php @@ -28,7 +28,7 @@ class ServerPluginsControllerTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Controllers/Server/ServerVariablesControllerTest.php b/test/classes/Controllers/Server/ServerVariablesControllerTest.php index 3591fd986a..aad884d3c5 100644 --- a/test/classes/Controllers/Server/ServerVariablesControllerTest.php +++ b/test/classes/Controllers/Server/ServerVariablesControllerTest.php @@ -35,7 +35,7 @@ class ServerVariablesControllerTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Controllers/Table/TableStructureControllerTest.php b/test/classes/Controllers/Table/TableStructureControllerTest.php index 5b2d426382..b2824e575a 100644 --- a/test/classes/Controllers/Table/TableStructureControllerTest.php +++ b/test/classes/Controllers/Table/TableStructureControllerTest.php @@ -36,7 +36,7 @@ class TableStructureControllerTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/CoreTest.php b/test/classes/CoreTest.php index 8d8f44f85e..2ec95d4e4e 100644 --- a/test/classes/CoreTest.php +++ b/test/classes/CoreTest.php @@ -46,7 +46,7 @@ class CoreTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['db'] = ''; @@ -59,7 +59,7 @@ class CoreTest extends PmaTestCase * * @return void */ - function testArrayRead() + public function testArrayRead() { $arr = [ "int" => 1, @@ -147,7 +147,7 @@ class CoreTest extends PmaTestCase * * @return void */ - function testArrayWrite() + public function testArrayWrite() { $arr = [ "int" => 1, @@ -201,7 +201,7 @@ class CoreTest extends PmaTestCase * * @return void */ - function testArrayRemove() + public function testArrayRemove() { $arr = [ "int" => 1, @@ -269,7 +269,7 @@ class CoreTest extends PmaTestCase * * @dataProvider providerTestGotoNowhere */ - function testGotoNowhere($page, $whiteList, $expected) + public function testGotoNowhere($page, $whiteList, $expected) { $this->assertSame($expected, Core::checkPageValidity($page, $whiteList)); } @@ -634,7 +634,7 @@ class CoreTest extends PmaTestCase * * @dataProvider provideTestIsAllowedDomain */ - function testIsAllowedDomain($url, $expected) + public function testIsAllowedDomain($url, $expected) { $_SERVER['SERVER_NAME'] = 'server.local'; $this->assertEquals( @@ -648,7 +648,7 @@ class CoreTest extends PmaTestCase * * @return array */ - function provideTestIsAllowedDomain() + public function provideTestIsAllowedDomain() { return [ ['https://www.phpmyadmin.net/', true], @@ -996,7 +996,7 @@ class CoreTest extends PmaTestCase * * @dataProvider provideTestSafeUnserialize */ - function testSafeUnserialize($data, $expected) + public function testSafeUnserialize($data, $expected) { $this->assertEquals( $expected, @@ -1009,7 +1009,7 @@ class CoreTest extends PmaTestCase * * @return array */ - function provideTestSafeUnserialize() + public function provideTestSafeUnserialize() { return [ ['s:6:"foobar";', 'foobar'], @@ -1035,7 +1035,7 @@ class CoreTest extends PmaTestCase * * @dataProvider provideTestSanitizeMySQLHost */ - function testSanitizeMySQLHost($host, $expected) + public function testSanitizeMySQLHost($host, $expected) { $this->assertEquals( $expected, @@ -1048,7 +1048,7 @@ class CoreTest extends PmaTestCase * * @return array */ - function provideTestSanitizeMySQLHost() + public function provideTestSanitizeMySQLHost() { return [ ['p:foo.bar', 'foo.bar'], @@ -1084,7 +1084,7 @@ class CoreTest extends PmaTestCase * * @return void */ - function testMissingExtensionFatal() + public function testMissingExtensionFatal() { $ext = 'php_ext'; $warn = 'The assertEquals( @@ -192,7 +192,7 @@ class FontTest extends PmaTestCase * * @return void */ - function testGetStringWidthSize() + public function testGetStringWidthSize() { // string "phpMyAdmin", with font size 0 $this->assertEquals( @@ -224,7 +224,7 @@ class FontTest extends PmaTestCase * * @return void */ - function testGetStringWidthCharLists() + public function testGetStringWidthCharLists() { // string "a", with invalid charlist (= array without proper structure) $this->assertEquals( diff --git a/test/classes/HeaderTest.php b/test/classes/HeaderTest.php index 229e48ed83..bb286f7ad5 100644 --- a/test/classes/HeaderTest.php +++ b/test/classes/HeaderTest.php @@ -28,7 +28,7 @@ class HeaderTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { if (!defined('PMA_IS_WINDOWS')) { define('PMA_IS_WINDOWS', false); diff --git a/test/classes/ImportTest.php b/test/classes/ImportTest.php index 31277c7a24..0c91ef9945 100644 --- a/test/classes/ImportTest.php +++ b/test/classes/ImportTest.php @@ -32,7 +32,7 @@ class ImportTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['cfg']['ServerDefault'] = ''; @@ -44,7 +44,7 @@ class ImportTest extends TestCase * * @return void */ - function testCheckTimeout() + public function testCheckTimeout() { global $timestamp, $maximum_time, $timeout_passed; @@ -89,7 +89,7 @@ class ImportTest extends TestCase * * @return void */ - function testLookForUse() + public function testLookForUse() { $this->assertEquals( [null, null], @@ -137,7 +137,7 @@ class ImportTest extends TestCase * * @dataProvider provGetColumnAlphaName */ - function testGetColumnAlphaName($expected, $num) + public function testGetColumnAlphaName($expected, $num) { $this->assertEquals($expected, $this->import->getColumnAlphaName($num)); } @@ -147,7 +147,7 @@ class ImportTest extends TestCase * * @return array */ - function provGetColumnAlphaName() + public function provGetColumnAlphaName() { return [ ['A', 1], @@ -169,7 +169,7 @@ class ImportTest extends TestCase * * @dataProvider provGetColumnNumberFromName */ - function testGetColumnNumberFromName($expected, $name) + public function testGetColumnNumberFromName($expected, $name) { $this->assertEquals($expected, $this->import->getColumnNumberFromName($name)); } @@ -179,7 +179,7 @@ class ImportTest extends TestCase * * @return array */ - function provGetColumnNumberFromName() + public function provGetColumnNumberFromName() { return [ [1, 'A'], @@ -201,7 +201,7 @@ class ImportTest extends TestCase * * @dataProvider provGetDecimalPrecision */ - function testGetDecimalPrecision($expected, $size) + public function testGetDecimalPrecision($expected, $size) { $this->assertEquals($expected, $this->import->getDecimalPrecision($size)); } @@ -211,7 +211,7 @@ class ImportTest extends TestCase * * @return array */ - function provGetDecimalPrecision() + public function provGetDecimalPrecision() { return [ [2, '2,1'], @@ -231,7 +231,7 @@ class ImportTest extends TestCase * * @dataProvider provGetDecimalScale */ - function testGetDecimalScale($expected, $size) + public function testGetDecimalScale($expected, $size) { $this->assertEquals($expected, $this->import->getDecimalScale($size)); } @@ -241,7 +241,7 @@ class ImportTest extends TestCase * * @return array */ - function provGetDecimalScale() + public function provGetDecimalScale() { return [ [1, '2,1'], @@ -261,7 +261,7 @@ class ImportTest extends TestCase * * @dataProvider provGetDecimalSize */ - function testGetDecimalSize($expected, $cell) + public function testGetDecimalSize($expected, $cell) { $this->assertEquals($expected, $this->import->getDecimalSize($cell)); } @@ -271,7 +271,7 @@ class ImportTest extends TestCase * * @return array */ - function provGetDecimalSize() + public function provGetDecimalSize() { return [ [[2, 1, '2,1'], '2.1'], @@ -294,7 +294,7 @@ class ImportTest extends TestCase * * @dataProvider provDetectType */ - function testDetectType($expected, $type, $cell) + public function testDetectType($expected, $type, $cell) { $this->assertEquals($expected, $this->import->detectType($type, $cell)); } @@ -304,7 +304,7 @@ class ImportTest extends TestCase * * @return array */ - function provDetectType() + public function provDetectType() { return [ [Import::NONE, null, 'NULL'], @@ -328,7 +328,7 @@ class ImportTest extends TestCase * * @return void */ - function testPMAGetMatchedRows() + public function testPMAGetMatchedRows() { $GLOBALS['db'] = 'PMA'; //mock DBI @@ -379,7 +379,7 @@ class ImportTest extends TestCase * * @return void */ - function simulatedQueryTest($sql_query, $simulated_query) + public function simulatedQueryTest($sql_query, $simulated_query) { $parser = new Parser($sql_query); $analyzed_sql_results = [ @@ -414,7 +414,7 @@ class ImportTest extends TestCase * * @return void */ - function testPMACheckIfRollbackPossible() + public function testPMACheckIfRollbackPossible() { $GLOBALS['db'] = 'PMA'; //mock DBI diff --git a/test/classes/IndexTest.php b/test/classes/IndexTest.php index 5483033c30..6e8f0a10f5 100644 --- a/test/classes/IndexTest.php +++ b/test/classes/IndexTest.php @@ -26,7 +26,7 @@ class IndexTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $this->_params['Schema'] = "PMA_Schema"; $this->_params['Table'] = "PMA_Table"; diff --git a/test/classes/InsertEditTest.php b/test/classes/InsertEditTest.php index a4c805cf72..35c2535164 100644 --- a/test/classes/InsertEditTest.php +++ b/test/classes/InsertEditTest.php @@ -34,7 +34,7 @@ class InsertEditTest extends TestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 1; $GLOBALS['PMA_PHP_SELF'] = 'index.php'; diff --git a/test/classes/LanguageTest.php b/test/classes/LanguageTest.php index dc6384719f..e480e0b307 100644 --- a/test/classes/LanguageTest.php +++ b/test/classes/LanguageTest.php @@ -29,7 +29,7 @@ class LanguageTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $loc = LOCALE_PATH . '/cs/LC_MESSAGES/phpmyadmin.mo'; if (! is_readable($loc)) { diff --git a/test/classes/ListDatabaseTest.php b/test/classes/ListDatabaseTest.php index 9d630ca50a..e82696d8dd 100644 --- a/test/classes/ListDatabaseTest.php +++ b/test/classes/ListDatabaseTest.php @@ -28,7 +28,7 @@ class ListDatabaseTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['cfg']['Server']['only_db'] = ['single\\_db']; $this->object = new ListDatabase(); diff --git a/test/classes/MenuTest.php b/test/classes/MenuTest.php index 87d7254c30..c70ddecf58 100644 --- a/test/classes/MenuTest.php +++ b/test/classes/MenuTest.php @@ -25,7 +25,7 @@ class MenuTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { if (!defined('PMA_IS_WINDOWS')) { define('PMA_IS_WINDOWS', false); @@ -45,7 +45,7 @@ class MenuTest extends PmaTestCase * * @return void */ - function testServer() + public function testServer() { $menu = new Menu('server', '', ''); $this->assertContains( @@ -59,7 +59,7 @@ class MenuTest extends PmaTestCase * * @return void */ - function testDatabase() + public function testDatabase() { $menu = new Menu('server', 'pma_test', ''); $this->assertContains( @@ -73,7 +73,7 @@ class MenuTest extends PmaTestCase * * @return void */ - function testTable() + public function testTable() { $menu = new Menu('server', 'pma_test', 'table1'); $this->assertContains( @@ -87,7 +87,7 @@ class MenuTest extends PmaTestCase * * @return void */ - function testTableDisplay() + public function testTableDisplay() { $menu = new Menu('server', 'pma_test', ''); $this->expectOutputString( @@ -102,7 +102,7 @@ class MenuTest extends PmaTestCase * * @return void */ - function testSetTable() + public function testSetTable() { $menu = new Menu('server', 'pma_test', ''); $menu->setTable('table1'); diff --git a/test/classes/Navigation/NodeFactoryTest.php b/test/classes/Navigation/NodeFactoryTest.php index 6ec8c0a4ae..310910477f 100644 --- a/test/classes/Navigation/NodeFactoryTest.php +++ b/test/classes/Navigation/NodeFactoryTest.php @@ -26,7 +26,7 @@ class NodeFactoryTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeColumnContainerTest.php b/test/classes/Navigation/Nodes/NodeColumnContainerTest.php index 164c6f864f..51923a922e 100644 --- a/test/classes/Navigation/Nodes/NodeColumnContainerTest.php +++ b/test/classes/Navigation/Nodes/NodeColumnContainerTest.php @@ -25,7 +25,7 @@ class NodeColumnContainerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeColumnTest.php b/test/classes/Navigation/Nodes/NodeColumnTest.php index 63090e9a7d..7420a7f771 100644 --- a/test/classes/Navigation/Nodes/NodeColumnTest.php +++ b/test/classes/Navigation/Nodes/NodeColumnTest.php @@ -25,7 +25,7 @@ class NodeColumnTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeDatabaseTest.php b/test/classes/Navigation/Nodes/NodeDatabaseTest.php index f08c5910eb..7a41076cb5 100644 --- a/test/classes/Navigation/Nodes/NodeDatabaseTest.php +++ b/test/classes/Navigation/Nodes/NodeDatabaseTest.php @@ -25,7 +25,7 @@ class NodeDatabaseTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['cfg']['DefaultTabDatabase'] = 'structure'; diff --git a/test/classes/Navigation/Nodes/NodeEventContainerTest.php b/test/classes/Navigation/Nodes/NodeEventContainerTest.php index 70b487da39..73bda5c030 100644 --- a/test/classes/Navigation/Nodes/NodeEventContainerTest.php +++ b/test/classes/Navigation/Nodes/NodeEventContainerTest.php @@ -25,7 +25,7 @@ class NodeEventContainerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeEventTest.php b/test/classes/Navigation/Nodes/NodeEventTest.php index 2207bd7d6b..5018676c66 100644 --- a/test/classes/Navigation/Nodes/NodeEventTest.php +++ b/test/classes/Navigation/Nodes/NodeEventTest.php @@ -25,7 +25,7 @@ class NodeEventTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeFunctionContainerTest.php b/test/classes/Navigation/Nodes/NodeFunctionContainerTest.php index 64815094e6..1697dd03a1 100644 --- a/test/classes/Navigation/Nodes/NodeFunctionContainerTest.php +++ b/test/classes/Navigation/Nodes/NodeFunctionContainerTest.php @@ -25,7 +25,7 @@ class NodeFunctionContainerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeFunctionTest.php b/test/classes/Navigation/Nodes/NodeFunctionTest.php index a43933d87a..51d80a1c03 100644 --- a/test/classes/Navigation/Nodes/NodeFunctionTest.php +++ b/test/classes/Navigation/Nodes/NodeFunctionTest.php @@ -25,7 +25,7 @@ class NodeFunctionTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeIndexContainerTest.php b/test/classes/Navigation/Nodes/NodeIndexContainerTest.php index c92a28fbb9..b6386ca2ba 100644 --- a/test/classes/Navigation/Nodes/NodeIndexContainerTest.php +++ b/test/classes/Navigation/Nodes/NodeIndexContainerTest.php @@ -25,7 +25,7 @@ class NodeIndexContainerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeIndexTest.php b/test/classes/Navigation/Nodes/NodeIndexTest.php index c152b42800..56e36bb342 100644 --- a/test/classes/Navigation/Nodes/NodeIndexTest.php +++ b/test/classes/Navigation/Nodes/NodeIndexTest.php @@ -25,7 +25,7 @@ class NodeIndexTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeProcedureContainerTest.php b/test/classes/Navigation/Nodes/NodeProcedureContainerTest.php index eaf465911a..cb59499b44 100644 --- a/test/classes/Navigation/Nodes/NodeProcedureContainerTest.php +++ b/test/classes/Navigation/Nodes/NodeProcedureContainerTest.php @@ -25,7 +25,7 @@ class NodeProcedureContainerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeProcedureTest.php b/test/classes/Navigation/Nodes/NodeProcedureTest.php index e798a1e67b..6d4a87b668 100644 --- a/test/classes/Navigation/Nodes/NodeProcedureTest.php +++ b/test/classes/Navigation/Nodes/NodeProcedureTest.php @@ -25,7 +25,7 @@ class NodeProcedureTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeTableContainerTest.php b/test/classes/Navigation/Nodes/NodeTableContainerTest.php index e8bd5ee922..689ab2dc8e 100644 --- a/test/classes/Navigation/Nodes/NodeTableContainerTest.php +++ b/test/classes/Navigation/Nodes/NodeTableContainerTest.php @@ -25,7 +25,7 @@ class NodeTableContainerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['cfg']['NavigationTreeEnableGrouping'] = true; diff --git a/test/classes/Navigation/Nodes/NodeTableTest.php b/test/classes/Navigation/Nodes/NodeTableTest.php index 4ef07cb7c6..8a39af7612 100644 --- a/test/classes/Navigation/Nodes/NodeTableTest.php +++ b/test/classes/Navigation/Nodes/NodeTableTest.php @@ -25,7 +25,7 @@ class NodeTableTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['cfg']['NavigationTreeDefaultTabTable'] = 'b_browse'; diff --git a/test/classes/Navigation/Nodes/NodeTest.php b/test/classes/Navigation/Nodes/NodeTest.php index fe4c59bfa6..477fec56ea 100644 --- a/test/classes/Navigation/Nodes/NodeTest.php +++ b/test/classes/Navigation/Nodes/NodeTest.php @@ -27,7 +27,7 @@ class NodeTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['cfg']['Server']['DisableIS'] = false; diff --git a/test/classes/Navigation/Nodes/NodeTriggerContainerTest.php b/test/classes/Navigation/Nodes/NodeTriggerContainerTest.php index dabd8fdd60..31ce523285 100644 --- a/test/classes/Navigation/Nodes/NodeTriggerContainerTest.php +++ b/test/classes/Navigation/Nodes/NodeTriggerContainerTest.php @@ -25,7 +25,7 @@ class NodeTriggerContainerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeTriggerTest.php b/test/classes/Navigation/Nodes/NodeTriggerTest.php index 7a8d5acf5b..fbd29b28fd 100644 --- a/test/classes/Navigation/Nodes/NodeTriggerTest.php +++ b/test/classes/Navigation/Nodes/NodeTriggerTest.php @@ -25,7 +25,7 @@ class NodeTriggerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/Navigation/Nodes/NodeViewContainerTest.php b/test/classes/Navigation/Nodes/NodeViewContainerTest.php index d42a973307..519bfe49ee 100644 --- a/test/classes/Navigation/Nodes/NodeViewContainerTest.php +++ b/test/classes/Navigation/Nodes/NodeViewContainerTest.php @@ -25,7 +25,7 @@ class NodeViewContainerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['cfg']['NavigationTreeEnableGrouping'] = true; diff --git a/test/classes/Navigation/Nodes/NodeViewTest.php b/test/classes/Navigation/Nodes/NodeViewTest.php index 598b81f6f3..9c4661adcb 100644 --- a/test/classes/Navigation/Nodes/NodeViewTest.php +++ b/test/classes/Navigation/Nodes/NodeViewTest.php @@ -25,7 +25,7 @@ class NodeViewTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['server'] = 0; } diff --git a/test/classes/NormalizationTest.php b/test/classes/NormalizationTest.php index 17c3b862e7..8c7cc52625 100644 --- a/test/classes/NormalizationTest.php +++ b/test/classes/NormalizationTest.php @@ -32,7 +32,7 @@ class NormalizationTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['cfg']['LimitChars'] = 50; $GLOBALS['cfg']['ServerDefault'] = "PMA_server"; diff --git a/test/classes/PdfTest.php b/test/classes/PdfTest.php index 17e8d6139a..dc1a6536eb 100644 --- a/test/classes/PdfTest.php +++ b/test/classes/PdfTest.php @@ -25,7 +25,7 @@ class PdfTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['PMA_Config'] = new Config(); $GLOBALS['PMA_Config']->enableBc(); diff --git a/test/classes/Plugins/Export/ExportCodegenTest.php b/test/classes/Plugins/Export/ExportCodegenTest.php index af50d3f8c8..fc880f0357 100644 --- a/test/classes/Plugins/Export/ExportCodegenTest.php +++ b/test/classes/Plugins/Export/ExportCodegenTest.php @@ -23,6 +23,9 @@ use ReflectionProperty; */ class ExportCodegenTest extends PmaTestCase { + /** + * @var ExportCodegen + */ protected $object; /** @@ -30,10 +33,10 @@ class ExportCodegenTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; - $this->object = new ExportCodegen(null); + $this->object = new ExportCodegen(); } /** diff --git a/test/classes/Plugins/Export/ExportCsvTest.php b/test/classes/Plugins/Export/ExportCsvTest.php index 45d1757a08..84a1b51c85 100644 --- a/test/classes/Plugins/Export/ExportCsvTest.php +++ b/test/classes/Plugins/Export/ExportCsvTest.php @@ -30,7 +30,7 @@ class ExportCsvTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $this->object = new ExportCsv(); diff --git a/test/classes/Plugins/Export/ExportExcelTest.php b/test/classes/Plugins/Export/ExportExcelTest.php index de94ef29b3..11c7c2306d 100644 --- a/test/classes/Plugins/Export/ExportExcelTest.php +++ b/test/classes/Plugins/Export/ExportExcelTest.php @@ -29,7 +29,7 @@ class ExportExcelTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $this->object = new ExportExcel(); diff --git a/test/classes/Plugins/Export/ExportHtmlwordTest.php b/test/classes/Plugins/Export/ExportHtmlwordTest.php index b7d9480ca1..47cdf10c1d 100644 --- a/test/classes/Plugins/Export/ExportHtmlwordTest.php +++ b/test/classes/Plugins/Export/ExportHtmlwordTest.php @@ -30,7 +30,7 @@ class ExportHtmlwordTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $this->object = new ExportHtmlword(); diff --git a/test/classes/Plugins/Export/ExportJsonTest.php b/test/classes/Plugins/Export/ExportJsonTest.php index 7403b83016..0b7fceb6dc 100644 --- a/test/classes/Plugins/Export/ExportJsonTest.php +++ b/test/classes/Plugins/Export/ExportJsonTest.php @@ -29,7 +29,7 @@ class ExportJsonTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/ExportLatexTest.php b/test/classes/Plugins/Export/ExportLatexTest.php index 10f9ce816a..3071426b53 100644 --- a/test/classes/Plugins/Export/ExportLatexTest.php +++ b/test/classes/Plugins/Export/ExportLatexTest.php @@ -29,7 +29,7 @@ class ExportLatexTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/ExportMediawikiTest.php b/test/classes/Plugins/Export/ExportMediawikiTest.php index b06f540dd9..f4c7868a06 100644 --- a/test/classes/Plugins/Export/ExportMediawikiTest.php +++ b/test/classes/Plugins/Export/ExportMediawikiTest.php @@ -30,7 +30,7 @@ class ExportMediawikiTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/ExportOdsTest.php b/test/classes/Plugins/Export/ExportOdsTest.php index eae5eb4103..4bc76e72fd 100644 --- a/test/classes/Plugins/Export/ExportOdsTest.php +++ b/test/classes/Plugins/Export/ExportOdsTest.php @@ -31,7 +31,7 @@ class ExportOdsTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/ExportOdtTest.php b/test/classes/Plugins/Export/ExportOdtTest.php index c7e1a3c9e5..c23cf5d83a 100644 --- a/test/classes/Plugins/Export/ExportOdtTest.php +++ b/test/classes/Plugins/Export/ExportOdtTest.php @@ -31,7 +31,7 @@ class ExportOdtTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/ExportPdfTest.php b/test/classes/Plugins/Export/ExportPdfTest.php index bae8b1f4e7..0ea70f9b63 100644 --- a/test/classes/Plugins/Export/ExportPdfTest.php +++ b/test/classes/Plugins/Export/ExportPdfTest.php @@ -30,7 +30,7 @@ class ExportPdfTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/ExportPhparrayTest.php b/test/classes/Plugins/Export/ExportPhparrayTest.php index cf2c4222db..0ed53f5bfe 100644 --- a/test/classes/Plugins/Export/ExportPhparrayTest.php +++ b/test/classes/Plugins/Export/ExportPhparrayTest.php @@ -30,7 +30,7 @@ class ExportPhparrayTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/ExportSqlTest.php b/test/classes/Plugins/Export/ExportSqlTest.php index 021da76da3..4ce3aebb12 100644 --- a/test/classes/Plugins/Export/ExportSqlTest.php +++ b/test/classes/Plugins/Export/ExportSqlTest.php @@ -32,7 +32,7 @@ class ExportSqlTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['db'] = 'db'; diff --git a/test/classes/Plugins/Export/ExportTexytextTest.php b/test/classes/Plugins/Export/ExportTexytextTest.php index 6d0a8b5462..32b809757b 100644 --- a/test/classes/Plugins/Export/ExportTexytextTest.php +++ b/test/classes/Plugins/Export/ExportTexytextTest.php @@ -30,7 +30,7 @@ class ExportTexytextTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/ExportXmlTest.php b/test/classes/Plugins/Export/ExportXmlTest.php index 851b9db788..062defc575 100644 --- a/test/classes/Plugins/Export/ExportXmlTest.php +++ b/test/classes/Plugins/Export/ExportXmlTest.php @@ -31,7 +31,7 @@ class ExportXmlTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/ExportYamlTest.php b/test/classes/Plugins/Export/ExportYamlTest.php index 441cf8050c..c31dc02a98 100644 --- a/test/classes/Plugins/Export/ExportYamlTest.php +++ b/test/classes/Plugins/Export/ExportYamlTest.php @@ -30,7 +30,7 @@ class ExportYamlTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $GLOBALS['output_kanji_conversion'] = false; diff --git a/test/classes/Plugins/Export/Helpers/TablePropertyTest.php b/test/classes/Plugins/Export/Helpers/TablePropertyTest.php index 9cdc6495d1..6f032a0679 100644 --- a/test/classes/Plugins/Export/Helpers/TablePropertyTest.php +++ b/test/classes/Plugins/Export/Helpers/TablePropertyTest.php @@ -26,7 +26,7 @@ class TablePropertyTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['server'] = 0; $row = [' name ', 'int ', true, ' PRI', '0', 'mysql']; diff --git a/test/classes/Properties/Options/Groups/OptionsPropertyMainGroupTest.php b/test/classes/Properties/Options/Groups/OptionsPropertyMainGroupTest.php index a7ef918a70..a0602973da 100644 --- a/test/classes/Properties/Options/Groups/OptionsPropertyMainGroupTest.php +++ b/test/classes/Properties/Options/Groups/OptionsPropertyMainGroupTest.php @@ -26,7 +26,7 @@ class OptionsPropertyMainGroupTest extends TestCase * * @return void */ - protected function setup() + protected function setUp() { $this->object = new OptionsPropertyMainGroup(); } diff --git a/test/classes/Properties/Options/Groups/OptionsPropertyRootGroupTest.php b/test/classes/Properties/Options/Groups/OptionsPropertyRootGroupTest.php index aa72390b7b..d25ef52063 100644 --- a/test/classes/Properties/Options/Groups/OptionsPropertyRootGroupTest.php +++ b/test/classes/Properties/Options/Groups/OptionsPropertyRootGroupTest.php @@ -26,7 +26,7 @@ class OptionsPropertyRootGroupTest extends TestCase * * @return void */ - protected function setup() + protected function setUp() { $this->object = new OptionsPropertyRootGroup(); } diff --git a/test/classes/Properties/Options/Groups/OptionsPropertySubgroupTest.php b/test/classes/Properties/Options/Groups/OptionsPropertySubgroupTest.php index 93de24e06a..e7a89d1f76 100644 --- a/test/classes/Properties/Options/Groups/OptionsPropertySubgroupTest.php +++ b/test/classes/Properties/Options/Groups/OptionsPropertySubgroupTest.php @@ -26,7 +26,7 @@ class OptionsPropertySubgroupTest extends TestCase * * @return void */ - protected function setup() + protected function setUp() { $this->object = new OptionsPropertySubgroup(); } diff --git a/test/classes/Properties/Options/OptionsPropertyGroupTest.php b/test/classes/Properties/Options/OptionsPropertyGroupTest.php index fb530d6258..0578a9348b 100644 --- a/test/classes/Properties/Options/OptionsPropertyGroupTest.php +++ b/test/classes/Properties/Options/OptionsPropertyGroupTest.php @@ -26,7 +26,7 @@ class OptionsPropertyGroupTest extends TestCase * * @return void */ - protected function setup() + protected function setUp() { $this->stub = $this->getMockForAbstractClass('PhpMyAdmin\Properties\Options\OptionsPropertyGroup'); } diff --git a/test/classes/Properties/Options/OptionsPropertyItemTest.php b/test/classes/Properties/Options/OptionsPropertyItemTest.php index 26349d0f03..8bad4e4cee 100644 --- a/test/classes/Properties/Options/OptionsPropertyItemTest.php +++ b/test/classes/Properties/Options/OptionsPropertyItemTest.php @@ -25,7 +25,7 @@ class OptionsPropertyItemTest extends TestCase * * @return void */ - protected function setup() + protected function setUp() { $this->stub = $this->getMockForAbstractClass('PhpMyAdmin\Properties\Options\OptionsPropertyItem'); } diff --git a/test/classes/Properties/Options/OptionsPropertyOneItemTest.php b/test/classes/Properties/Options/OptionsPropertyOneItemTest.php index 80ff8a15ee..ade432b439 100644 --- a/test/classes/Properties/Options/OptionsPropertyOneItemTest.php +++ b/test/classes/Properties/Options/OptionsPropertyOneItemTest.php @@ -25,7 +25,7 @@ class OptionsPropertyOneItemTest extends TestCase * * @return void */ - protected function setup() + protected function setUp() { $this->stub = $this->getMockForAbstractClass('PhpMyAdmin\Properties\Options\OptionsPropertyOneItem'); } diff --git a/test/classes/Properties/Plugins/ExportPluginPropertiesTest.php b/test/classes/Properties/Plugins/ExportPluginPropertiesTest.php index 7ea14591b6..a6e5d2d657 100644 --- a/test/classes/Properties/Plugins/ExportPluginPropertiesTest.php +++ b/test/classes/Properties/Plugins/ExportPluginPropertiesTest.php @@ -27,7 +27,7 @@ class ExportPluginPropertiesTest extends ImportPluginPropertiesTest * * @return void */ - protected function setup() + protected function setUp() { $this->object = new ExportPluginProperties(); } diff --git a/test/classes/Properties/Plugins/ImportPluginPropertiesTest.php b/test/classes/Properties/Plugins/ImportPluginPropertiesTest.php index 40f288108a..c08bae7452 100644 --- a/test/classes/Properties/Plugins/ImportPluginPropertiesTest.php +++ b/test/classes/Properties/Plugins/ImportPluginPropertiesTest.php @@ -26,7 +26,7 @@ class ImportPluginPropertiesTest extends TestCase * * @return void */ - protected function setup() + protected function setUp() { $this->object = new ImportPluginProperties(); } diff --git a/test/classes/Properties/Plugins/PluginPropertyItemTest.php b/test/classes/Properties/Plugins/PluginPropertyItemTest.php index 959f826bd7..92a19bde05 100644 --- a/test/classes/Properties/Plugins/PluginPropertyItemTest.php +++ b/test/classes/Properties/Plugins/PluginPropertyItemTest.php @@ -25,7 +25,7 @@ class PluginPropertyItemTest extends TestCase * * @return void */ - protected function setup() + protected function setUp() { $this->stub = $this->getMockForAbstractClass('PhpMyAdmin\Properties\Plugins\PluginPropertyItem'); } diff --git a/test/classes/Properties/PropertyItemTest.php b/test/classes/Properties/PropertyItemTest.php index 4660955176..81312af3e4 100644 --- a/test/classes/Properties/PropertyItemTest.php +++ b/test/classes/Properties/PropertyItemTest.php @@ -25,7 +25,7 @@ class PropertyItemTest extends TestCase * * @return void */ - protected function setup() + protected function setUp() { $this->stub = $this->getMockForAbstractClass('PhpMyAdmin\Properties\PropertyItem'); } diff --git a/test/classes/RelationCleanupDbiMock.php b/test/classes/RelationCleanupDbiMock.php index 3d6f9e04f6..5e5e5ce694 100644 --- a/test/classes/RelationCleanupDbiMock.php +++ b/test/classes/RelationCleanupDbiMock.php @@ -20,11 +20,11 @@ use PhpMyAdmin\DatabaseInterface; */ class RelationCleanupDbiMock extends DatabaseInterface { - var $index; - var $assocIndex; - var $totalNum; - var $values = []; - var $indexs = []; + public $index; + public $assocIndex; + public $totalNum; + public $values = []; + public $indexs = []; /** * Constructor diff --git a/test/classes/RelationCleanupTest.php b/test/classes/RelationCleanupTest.php index ea924b8695..544daf4c7d 100644 --- a/test/classes/RelationCleanupTest.php +++ b/test/classes/RelationCleanupTest.php @@ -34,7 +34,7 @@ class RelationCleanupTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { $_SESSION['relation'] = []; $GLOBALS['server'] = 1; diff --git a/test/classes/ReplicationGuiTest.php b/test/classes/ReplicationGuiTest.php index 804defe2f0..0578ea7f50 100644 --- a/test/classes/ReplicationGuiTest.php +++ b/test/classes/ReplicationGuiTest.php @@ -33,7 +33,7 @@ class ReplicationGuiTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Server/PrivilegesTest.php b/test/classes/Server/PrivilegesTest.php index 116d044dfb..38f5290715 100644 --- a/test/classes/Server/PrivilegesTest.php +++ b/test/classes/Server/PrivilegesTest.php @@ -35,7 +35,7 @@ class PrivilegesTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { //Constants if (!defined("PMA_USR_BROWSER_AGENT")) { @@ -2366,7 +2366,7 @@ class PrivilegesTest extends TestCase * * @return void */ - function testGetHtmlForViewUsersError() + public function testGetHtmlForViewUsersError() { $this->assertContains( 'Not enough privilege to view users.', @@ -2379,7 +2379,7 @@ class PrivilegesTest extends TestCase * * @return void */ - function testGetHtmlForUserProperties() + public function testGetHtmlForUserProperties() { $actual = $this->serverPrivileges->getHtmlForUserProperties( false, @@ -2407,7 +2407,7 @@ class PrivilegesTest extends TestCase * * @return void */ - function testGetHtmlForUserOverview() + public function testGetHtmlForUserOverview() { $actual = $this->serverPrivileges->getHtmlForUserOverview('theme', ''); $this->assertContains( @@ -2426,7 +2426,7 @@ class PrivilegesTest extends TestCase * * @return void */ - function testGetHtmlForAllTableSpecificRights() + public function testGetHtmlForAllTableSpecificRights() { // Test case 1 $actual = $this->serverPrivileges->getHtmlForAllTableSpecificRights('pma', 'host', 'table', 'pmadb'); @@ -2466,7 +2466,7 @@ class PrivilegesTest extends TestCase * * @return void */ - function testGetHtmlForInitials() + public function testGetHtmlForInitials() { // Setup for the test $GLOBALS['dbi']->expects($this->any())->method('fetchRow') @@ -2492,7 +2492,7 @@ class PrivilegesTest extends TestCase * * @return void */ - function testGetDbRightsForUserOverview() + public function testGetDbRightsForUserOverview() { //Mock DBI $dbi = $this->getMockBuilder('PhpMyAdmin\DatabaseInterface') @@ -2538,7 +2538,7 @@ class PrivilegesTest extends TestCase * * @return void */ - function testGetHtmlForAuthPluginsDropdown() + public function testGetHtmlForAuthPluginsDropdown() { $oldDbi = $GLOBALS['dbi']; @@ -2652,7 +2652,7 @@ class PrivilegesTest extends TestCase * * @return void */ - function testDeleteUser() + public function testDeleteUser() { //Mock DBI $dbi = $this->getMockBuilder('PhpMyAdmin\DatabaseInterface') diff --git a/test/classes/Server/SelectTest.php b/test/classes/Server/SelectTest.php index 35007f231d..bdd379e00e 100644 --- a/test/classes/Server/SelectTest.php +++ b/test/classes/Server/SelectTest.php @@ -28,7 +28,7 @@ class SelectTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Server/Status/AdvisorTest.php b/test/classes/Server/Status/AdvisorTest.php index d54bc3a478..342dd1d7b5 100644 --- a/test/classes/Server/Status/AdvisorTest.php +++ b/test/classes/Server/Status/AdvisorTest.php @@ -37,7 +37,7 @@ class AdvisorTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Server/Status/DataTest.php b/test/classes/Server/Status/DataTest.php index f35c31a928..c143f06f91 100644 --- a/test/classes/Server/Status/DataTest.php +++ b/test/classes/Server/Status/DataTest.php @@ -22,6 +22,7 @@ use PhpMyAdmin\Tests\PmaTestCase; class DataTest extends PmaTestCase { /** + * @var Data * @access protected */ protected $object; @@ -31,7 +32,7 @@ class DataTest extends PmaTestCase * * @return void */ - function setup() + protected function setUp() { $GLOBALS['PMA_PHP_SELF'] = Core::getenv('PHP_SELF'); $GLOBALS['cfg']['Server']['host'] = "::1"; @@ -110,7 +111,7 @@ class DataTest extends PmaTestCase * * @return void */ - function testGetMenuHtml() + public function testGetMenuHtml() { $html = $this->object->getMenuHtml(); diff --git a/test/classes/Server/Status/ProcessesTest.php b/test/classes/Server/Status/ProcessesTest.php index ba65bbc4ca..7fc981da06 100644 --- a/test/classes/Server/Status/ProcessesTest.php +++ b/test/classes/Server/Status/ProcessesTest.php @@ -29,7 +29,7 @@ class ProcessesTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['cfg']['Server']['host'] = "localhost"; $GLOBALS['PMA_PHP_SELF'] = Core::getenv('PHP_SELF'); diff --git a/test/classes/Server/Status/QueriesTest.php b/test/classes/Server/Status/QueriesTest.php index beb2a93bfd..18c6bb2817 100644 --- a/test/classes/Server/Status/QueriesTest.php +++ b/test/classes/Server/Status/QueriesTest.php @@ -38,7 +38,7 @@ class QueriesTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { //$GLOBALS $GLOBALS['cfg']['MaxRows'] = 10; diff --git a/test/classes/Server/Status/VariablesTest.php b/test/classes/Server/Status/VariablesTest.php index bedb7984f5..da1385905a 100644 --- a/test/classes/Server/Status/VariablesTest.php +++ b/test/classes/Server/Status/VariablesTest.php @@ -35,7 +35,7 @@ class VariablesTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { //$_REQUEST $_REQUEST['log'] = "index1"; diff --git a/test/classes/Server/StatusTest.php b/test/classes/Server/StatusTest.php index 2ecaa6d511..e655e9b22f 100644 --- a/test/classes/Server/StatusTest.php +++ b/test/classes/Server/StatusTest.php @@ -37,7 +37,7 @@ class StatusTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['cfg']['Server']['host'] = "localhost"; $GLOBALS['cfg']['ShowHint'] = true; diff --git a/test/classes/Server/UserGroupsTest.php b/test/classes/Server/UserGroupsTest.php index 7394d736f6..a031fe612f 100644 --- a/test/classes/Server/UserGroupsTest.php +++ b/test/classes/Server/UserGroupsTest.php @@ -26,7 +26,7 @@ class UserGroupsTest extends TestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['cfg']['ServerDefault'] = 1; $GLOBALS['cfg']['ActionLinksMode'] = 'both'; diff --git a/test/classes/Setup/FormProcessingTest.php b/test/classes/Setup/FormProcessingTest.php index 41aa3c7853..6fd93dc8e3 100644 --- a/test/classes/Setup/FormProcessingTest.php +++ b/test/classes/Setup/FormProcessingTest.php @@ -24,7 +24,7 @@ class FormProcessingTest extends PmaTestCase * * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['server'] = 1; $GLOBALS['db'] = 'db'; diff --git a/test/classes/Setup/IndexTest.php b/test/classes/Setup/IndexTest.php index e51089a39b..a9d470a130 100644 --- a/test/classes/Setup/IndexTest.php +++ b/test/classes/Setup/IndexTest.php @@ -24,7 +24,7 @@ class IndexTest extends TestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['cfg']['ProxyUrl'] = ''; } diff --git a/test/classes/ThemeManagerTest.php b/test/classes/ThemeManagerTest.php index 44091ec2cf..03f1296480 100644 --- a/test/classes/ThemeManagerTest.php +++ b/test/classes/ThemeManagerTest.php @@ -25,7 +25,7 @@ class ThemeManagerTest extends PmaTestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['cfg']['ThemePerServer'] = false; $GLOBALS['cfg']['ThemeDefault'] = 'pmahomme'; diff --git a/test/classes/TransformationsTest.php b/test/classes/TransformationsTest.php index 12c838cf25..5a5b8faaf0 100644 --- a/test/classes/TransformationsTest.php +++ b/test/classes/TransformationsTest.php @@ -30,7 +30,7 @@ class TransformationsTest extends TestCase * * @return void */ - public function setup() + protected function setUp() { $GLOBALS['table'] = 'table'; $GLOBALS['db'] = 'db'; diff --git a/test/classes/TwoFactorTest.php b/test/classes/TwoFactorTest.php index 01c1623f54..c9f07c27fc 100644 --- a/test/classes/TwoFactorTest.php +++ b/test/classes/TwoFactorTest.php @@ -23,7 +23,7 @@ class TwoFactorTest extends PmaTestCase /** * @return void */ - public function setUp() + protected function setUp() { $GLOBALS['server'] = 1; $GLOBALS['db'] = 'db'; diff --git a/test/classes/UrlTest.php b/test/classes/UrlTest.php index ddd3e57cea..f90ba52fc1 100644 --- a/test/classes/UrlTest.php +++ b/test/classes/UrlTest.php @@ -26,7 +26,7 @@ class UrlTest extends TestCase * @access protected * @return void */ - public function setUp() + protected function setUp() { unset($_COOKIE['pma_lang']); } diff --git a/test/classes/UtilTest.php b/test/classes/UtilTest.php index 4d41ee9042..b91be0486b 100644 --- a/test/classes/UtilTest.php +++ b/test/classes/UtilTest.php @@ -156,10 +156,10 @@ class UtilTest extends PmaTestCase * * @return void * - * @covers PhpMyAdmin\Util::getBrowseUploadFileBlock + * @covers \PhpMyAdmin\Util::getBrowseUploadFileBlock * @dataProvider providerGetBrowseUploadFileBlock */ - function testGetBrowseUploadFileBlock($size, $unit, $res) + public function testGetBrowseUploadFileBlock($size, $unit, $res) { $GLOBALS['is_upload'] = false; $this->assertEquals( @@ -196,11 +196,11 @@ class UtilTest extends PmaTestCase /** * Test for PhpMyAdmin\Util::buildActionTitles * - * @covers PhpMyAdmin\Util::buildActionTitles + * @covers \PhpMyAdmin\Util::buildActionTitles * * @return void */ - function testBuildActionTitles() + public function testBuildActionTitles() { $GLOBALS['cfg'] = ['ActionLinksMode' => 'both']; @@ -231,7 +231,7 @@ class UtilTest extends PmaTestCase /** * Test if cached data is available after set * - * @covers PhpMyAdmin\Util::cacheExists + * @covers \PhpMyAdmin\Util::cacheExists * * @return void */ @@ -249,7 +249,7 @@ class UtilTest extends PmaTestCase /** * Test if PhpMyAdmin\Util::cacheGet does not return data for non existing cache entries * - * @covers PhpMyAdmin\Util::cacheGet + * @covers \PhpMyAdmin\Util::cacheGet * * @return void */ @@ -267,7 +267,7 @@ class UtilTest extends PmaTestCase /** * Test retrieval of cached data * - * @covers PhpMyAdmin\Util::cacheSet + * @covers \PhpMyAdmin\Util::cacheSet * * @return void */ @@ -285,7 +285,7 @@ class UtilTest extends PmaTestCase /** * Test clearing cached values * - * @covers PhpMyAdmin\Util::cacheUnset + * @covers \PhpMyAdmin\Util::cacheUnset * * @return void */ @@ -310,7 +310,7 @@ class UtilTest extends PmaTestCase /** * Test clearing user cache * - * @covers PhpMyAdmin\Util::clearUserCache + * @covers \PhpMyAdmin\Util::clearUserCache * * @return void */ @@ -333,11 +333,11 @@ class UtilTest extends PmaTestCase /** * Test for Util::checkParameters * - * @covers PhpMyAdmin\Util::checkParameters + * @covers \PhpMyAdmin\Util::checkParameters * * @return void */ - function testCheckParameterMissing() + public function testCheckParameterMissing() { $GLOBALS['PMA_Config'] = new Config(); $GLOBALS['text_dir'] = 'ltr'; @@ -359,11 +359,11 @@ class UtilTest extends PmaTestCase /** * Test for Util::checkParameters * - * @covers PhpMyAdmin\Util::checkParameters + * @covers \PhpMyAdmin\Util::checkParameters * * @return void */ - function testCheckParameter() + public function testCheckParameter() { $GLOBALS['PMA_Config'] = new Config(); $GLOBALS['cfg'] = ['ServerDefault' => 1]; @@ -389,7 +389,7 @@ class UtilTest extends PmaTestCase * * @return void * - * @covers PhpMyAdmin\Util::containsNonPrintableAscii + * @covers \PhpMyAdmin\Util::containsNonPrintableAscii * @dataProvider providerContainsNonPrintableAscii */ public function testContainsNonPrintableAscii($str, $res) @@ -424,7 +424,7 @@ class UtilTest extends PmaTestCase * * @return void * - * @covers PhpMyAdmin\Util::convertBitDefaultValue + * @covers \PhpMyAdmin\Util::convertBitDefaultValue * @dataProvider providerConvertBitDefaultValue */ public function testConvertBitDefaultValue($bit, $val) @@ -476,7 +476,7 @@ class UtilTest extends PmaTestCase * * @return void * - * @covers PhpMyAdmin\Util::escapeMysqlWildcards + * @covers \PhpMyAdmin\Util::escapeMysqlWildcards * @dataProvider providerUnEscapeMysqlWildcards */ public function testEscapeMysqlWildcards($a, $b) @@ -495,7 +495,7 @@ class UtilTest extends PmaTestCase * * @return void * - * @covers PhpMyAdmin\Util::unescapeMysqlWildcards + * @covers \PhpMyAdmin\Util::unescapeMysqlWildcards * @dataProvider providerUnEscapeMysqlWildcards */ public function testUnescapeMysqlWildcards($a, $b) @@ -514,7 +514,7 @@ class UtilTest extends PmaTestCase * * @return void * - * @covers PhpMyAdmin\Util::expandUserString + * @covers \PhpMyAdmin\Util::expandUserString * @dataProvider providerExpandUserString */ public function testExpandUserString($in, $out) @@ -571,7 +571,7 @@ class UtilTest extends PmaTestCase * * @return void * - * @covers PhpMyAdmin\Util::extractColumnSpec + * @covers \PhpMyAdmin\Util::extractColumnSpec * @dataProvider providerExtractColumnSpec */ public function testExtractColumnSpec($in, $out) @@ -708,10 +708,10 @@ class UtilTest extends PmaTestCase * * @return void * - * @covers PhpMyAdmin\Util::extractValueFromFormattedSize + * @covers \PhpMyAdmin\Util::extractValueFromFormattedSize * @dataProvider providerExtractValueFromFormattedSize */ - function testExtractValueFromFormattedSize($size, $expected) + public function testExtractValueFromFormattedSize($size, $expected) { $this->assertEquals( $expected, @@ -742,7 +742,7 @@ class UtilTest extends PmaTestCase * * @return void * - * @covers PhpMyAdmin\Util::isForeignKeySupported + * @covers \PhpMyAdmin\Util::isForeignKeySupported * @dataProvider providerIsForeignKeySupported */ public function testIsForeignKeySupported($a, $e) @@ -773,11 +773,11 @@ class UtilTest extends PmaTestCase /** * Test for formatSql * - * @covers PhpMyAdmin\Util::formatSql + * @covers \PhpMyAdmin\Util::formatSql * * @return void */ - function testFormatSql() + public function testFormatSql() { $this->assertEquals( '
' . "\n"
@@ -806,7 +806,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::formatByteDown
+     * @covers \PhpMyAdmin\Util::formatByteDown
      * @dataProvider providerFormatByteDown
      */
     public function testFormatByteDown($a, $b, $c, $e)
@@ -869,7 +869,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::formatNumber
+     * @covers \PhpMyAdmin\Util::formatNumber
      * @dataProvider providerFormatNumber
      */
     public function testFormatNumber($a, $b, $c, $d)
@@ -948,7 +948,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::generateHiddenMaxFileSize
+     * @covers \PhpMyAdmin\Util::generateHiddenMaxFileSize
      * @dataProvider providerGenerateHiddenMaxFileSize
      */
     public function testGenerateHiddenMaxFileSize($size)
@@ -981,7 +981,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDbLink
+     * @covers \PhpMyAdmin\Util::getDbLink
      * @group medium
      */
     public function testGetDbLinkEmpty()
@@ -995,7 +995,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDbLink
+     * @covers \PhpMyAdmin\Util::getDbLink
      * @group medium
      */
     public function testGetDbLinkNull()
@@ -1024,7 +1024,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDbLink
+     * @covers \PhpMyAdmin\Util::getDbLink
      */
     public function testGetDbLink()
     {
@@ -1049,7 +1049,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDbLink
+     * @covers \PhpMyAdmin\Util::getDbLink
      */
     public function testGetDbLinkWithSpecialChars()
     {
@@ -1076,7 +1076,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDivForSliderEffect
+     * @covers \PhpMyAdmin\Util::getDivForSliderEffect
      */
     public function testGetDivForSliderEffectTest()
     {
@@ -1098,7 +1098,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDivForSliderEffect
+     * @covers \PhpMyAdmin\Util::getDivForSliderEffect
      */
     public function testGetDivForSliderEffectTestClosed()
     {
@@ -1120,7 +1120,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDivForSliderEffect
+     * @covers \PhpMyAdmin\Util::getDivForSliderEffect
      */
     public function testGetDivForSliderEffectTestDisabled()
     {
@@ -1141,7 +1141,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDropdown
+     * @covers \PhpMyAdmin\Util::getDropdown
      */
     public function testGetDropdownEmpty()
     {
@@ -1169,7 +1169,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDropdown
+     * @covers \PhpMyAdmin\Util::getDropdown
      */
     public function testGetDropdown()
     {
@@ -1205,7 +1205,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getDropdown
+     * @covers \PhpMyAdmin\Util::getDropdown
      */
     public function testGetDropdownWithActive()
     {
@@ -1247,7 +1247,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getFormattedMaximumUploadSize
+     * @covers \PhpMyAdmin\Util::getFormattedMaximumUploadSize
      * @dataProvider providerGetFormattedMaximumUploadSize
      */
     public function testGetFormattedMaximumUploadSize($size, $unit, $res)
@@ -1281,7 +1281,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getIcon
+     * @covers \PhpMyAdmin\Util::getIcon
      */
     public function testGetIconWithoutActionLinksMode()
     {
@@ -1298,7 +1298,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getIcon
+     * @covers \PhpMyAdmin\Util::getIcon
      */
     public function testGetIconWithActionLinksMode()
     {
@@ -1315,7 +1315,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getIcon
+     * @covers \PhpMyAdmin\Util::getIcon
      */
     public function testGetIconAlternate()
     {
@@ -1335,7 +1335,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getIcon
+     * @covers \PhpMyAdmin\Util::getIcon
      */
     public function testGetIconWithForceText()
     {
@@ -1357,7 +1357,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getRadioFields
+     * @covers \PhpMyAdmin\Util::getRadioFields
      */
     public function testGetRadioFieldsEmpty()
     {
@@ -1375,7 +1375,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getRadioFields
+     * @covers \PhpMyAdmin\Util::getRadioFields
      */
     public function testGetRadioFields()
     {
@@ -1406,7 +1406,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getRadioFields
+     * @covers \PhpMyAdmin\Util::getRadioFields
      */
     public function testGetRadioFieldsWithChecked()
     {
@@ -1445,7 +1445,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getRadioFields
+     * @covers \PhpMyAdmin\Util::getRadioFields
      */
     public function testGetRadioFieldsWithCheckedWithClass()
     {
@@ -1492,7 +1492,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getRadioFields
+     * @covers \PhpMyAdmin\Util::getRadioFields
      */
     public function testGetRadioFieldsWithoutBR()
     {
@@ -1530,7 +1530,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getRadioFields
+     * @covers \PhpMyAdmin\Util::getRadioFields
      */
     public function testGetRadioFieldsEscapeLabelEscapeLabel()
     {
@@ -1571,7 +1571,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getRadioFields
+     * @covers \PhpMyAdmin\Util::getRadioFields
      */
     public function testGetRadioFieldsEscapeLabelNotEscapeLabel()
     {
@@ -1612,7 +1612,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getRadioFields
+     * @covers \PhpMyAdmin\Util::getRadioFields
      */
     public function testGetRadioFieldsEscapeLabelEscapeLabelWithClass()
     {
@@ -1662,7 +1662,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::getTitleForTarget
+     * @covers \PhpMyAdmin\Util::getTitleForTarget
      * @dataProvider providerGetTitleForTarget
      */
     public function testGetTitleForTarget($target, $result)
@@ -1702,7 +1702,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::localisedDate
+     * @covers \PhpMyAdmin\Util::localisedDate
      * @dataProvider providerLocalisedDate
      */
     public function testLocalisedDate($a, $b, $e)
@@ -1739,7 +1739,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::timespanFormat
+     * @covers \PhpMyAdmin\Util::timespanFormat
      * @dataProvider providerTimespanFormat
      */
     public function testTimespanFormat($a, $e)
@@ -1778,7 +1778,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::printableBitValue
+     * @covers \PhpMyAdmin\Util::printableBitValue
      * @dataProvider providerPrintableBitValue
      */
     public function testPrintableBitValue($a, $b, $e)
@@ -1814,7 +1814,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::unQuote
+     * @covers \PhpMyAdmin\Util::unQuote
      * @dataProvider providerUnQuote
      */
     public function testUnQuote($param, $expected)
@@ -1848,7 +1848,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::unQuote
+     * @covers \PhpMyAdmin\Util::unQuote
      * @dataProvider providerUnQuoteSelectedChar
      */
     public function testUnQuoteSelectedChar($param, $expected)
@@ -1882,7 +1882,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::backquote
+     * @covers \PhpMyAdmin\Util::backquote
      * @dataProvider providerBackquote
      */
     public function testBackquote($a, $b)
@@ -1920,7 +1920,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::backquoteCompat
+     * @covers \PhpMyAdmin\Util::backquoteCompat
      * @dataProvider providerBackquoteCompat
      */
     public function testBackquoteCompat($a, $b)
@@ -1959,7 +1959,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::backquote
+     * @covers \PhpMyAdmin\Util::backquote
      */
     public function testBackquoteForbidenWords()
     {
@@ -1983,7 +1983,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::showDocu
+     * @covers \PhpMyAdmin\Util::showDocu
      */
     public function testShowDocu()
     {
@@ -2001,7 +2001,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::showPHPDocu
+     * @covers \PhpMyAdmin\Util::showPHPDocu
      */
     public function testShowPHPDocu()
     {
@@ -2029,7 +2029,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::userDir
+     * @covers \PhpMyAdmin\Util::userDir
      * @dataProvider providerUserDir
      */
     public function testUserDir($a, $e)
@@ -2060,7 +2060,7 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::duplicateFirstNewline
+     * @covers \PhpMyAdmin\Util::duplicateFirstNewline
      * @dataProvider providerDuplicateFirstNewline
      */
     public function testDuplicateFirstNewline($a, $e)
@@ -2091,9 +2091,9 @@ class UtilTest extends PmaTestCase
      *
      * @return void
      *
-     * @covers PhpMyAdmin\Util::unsupportedDatatypes
+     * @covers \PhpMyAdmin\Util::unsupportedDatatypes
      */
-    function testUnsupportedDatatypes()
+    public function testUnsupportedDatatypes()
     {
         $no_support_types = [];
         $this->assertEquals(
diff --git a/test/libraries/common/GetCheckboxTest.php b/test/libraries/common/GetCheckboxTest.php
index 669584ac3d..ebe418408d 100644
--- a/test/libraries/common/GetCheckboxTest.php
+++ b/test/libraries/common/GetCheckboxTest.php
@@ -26,7 +26,7 @@ class GetCheckboxTest extends TestCase
      *
      * @return void
      */
-    function testGetCheckbox()
+    public function testGetCheckbox()
     {
         $name = "test_display_html_checkbox";
         $label = "text_label_for_checkbox";
@@ -55,7 +55,7 @@ class GetCheckboxTest extends TestCase
      *
      * @return void
      */
-    function testGetCheckboxChecked()
+    public function testGetCheckboxChecked()
     {
         $name = "test_display_html_checkbox";
         $label = "text_label_for_checkbox";
@@ -82,7 +82,7 @@ class GetCheckboxTest extends TestCase
      *
      * @return void
      */
-    function testGetCheckboxOnclick()
+    public function testGetCheckboxOnclick()
     {
         $name = "test_display_html_checkbox";
         $label = "text_label_for_checkbox";
@@ -109,7 +109,7 @@ class GetCheckboxTest extends TestCase
      *
      * @return void
      */
-    function testGetCheckboxCheckedOnclick()
+    public function testGetCheckboxCheckedOnclick()
     {
         $name = "test_display_html_checkbox";
         $label = "text_label_for_checkbox";
diff --git a/test/selenium/CreateDropDatabaseTest.php b/test/selenium/CreateDropDatabaseTest.php
index 3e3474765e..95eaac97a6 100644
--- a/test/selenium/CreateDropDatabaseTest.php
+++ b/test/selenium/CreateDropDatabaseTest.php
@@ -24,7 +24,7 @@ class CreateDropDatabaseTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         /* TODO: For now this tests needs superuser for deleting database */
diff --git a/test/selenium/CreateRemoveUserTest.php b/test/selenium/CreateRemoveUserTest.php
index d882188e6c..d10f0816b0 100644
--- a/test/selenium/CreateRemoveUserTest.php
+++ b/test/selenium/CreateRemoveUserTest.php
@@ -40,7 +40,7 @@ class CreateRemoveUserTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->skipIfNotSuperUser();
diff --git a/test/selenium/DbEventsTest.php b/test/selenium/DbEventsTest.php
index 8b163aecd4..3b01a68b6c 100644
--- a/test/selenium/DbEventsTest.php
+++ b/test/selenium/DbEventsTest.php
@@ -24,7 +24,7 @@ class DbEventsTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(
diff --git a/test/selenium/DbProceduresTest.php b/test/selenium/DbProceduresTest.php
index 2b620390c9..21606522c6 100644
--- a/test/selenium/DbProceduresTest.php
+++ b/test/selenium/DbProceduresTest.php
@@ -24,7 +24,7 @@ class DbProceduresTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(
diff --git a/test/selenium/DbStructureTest.php b/test/selenium/DbStructureTest.php
index 12e6021adf..89ad92c691 100644
--- a/test/selenium/DbStructureTest.php
+++ b/test/selenium/DbStructureTest.php
@@ -24,7 +24,7 @@ class DbStructureTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(
diff --git a/test/selenium/DbTriggersTest.php b/test/selenium/DbTriggersTest.php
index 036c5cd3e9..4871c894b6 100644
--- a/test/selenium/DbTriggersTest.php
+++ b/test/selenium/DbTriggersTest.php
@@ -24,7 +24,7 @@ class DbTriggersTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(
diff --git a/test/selenium/ExportTest.php b/test/selenium/ExportTest.php
index 2d77cce0ff..fc49d65ce3 100644
--- a/test/selenium/ExportTest.php
+++ b/test/selenium/ExportTest.php
@@ -24,7 +24,7 @@ class ExportTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(
diff --git a/test/selenium/NormalizationTest.php b/test/selenium/NormalizationTest.php
index 1bacfbb23b..18d2da2ea2 100644
--- a/test/selenium/NormalizationTest.php
+++ b/test/selenium/NormalizationTest.php
@@ -24,7 +24,7 @@ class NormalizationTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(
diff --git a/test/selenium/QueryByExampleTest.php b/test/selenium/QueryByExampleTest.php
index 12ff852e76..c20468a692 100644
--- a/test/selenium/QueryByExampleTest.php
+++ b/test/selenium/QueryByExampleTest.php
@@ -25,7 +25,7 @@ class QueryByExampleTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         $this->markTestSkipped('Broken, see https://github.com/phpmyadmin/phpmyadmin/issues/13621');
         parent::setUp();
diff --git a/test/selenium/SqlQueryTest.php b/test/selenium/SqlQueryTest.php
index e7c28a52d5..b79065fdab 100644
--- a/test/selenium/SqlQueryTest.php
+++ b/test/selenium/SqlQueryTest.php
@@ -24,7 +24,7 @@ class SqlQueryTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
 
diff --git a/test/selenium/TableBrowseTest.php b/test/selenium/TableBrowseTest.php
index 12683a70b0..8e979934f5 100644
--- a/test/selenium/TableBrowseTest.php
+++ b/test/selenium/TableBrowseTest.php
@@ -26,7 +26,7 @@ class TableBrowseTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(
diff --git a/test/selenium/TableInsertTest.php b/test/selenium/TableInsertTest.php
index d3002b1a8f..928188d429 100644
--- a/test/selenium/TableInsertTest.php
+++ b/test/selenium/TableInsertTest.php
@@ -25,7 +25,7 @@ class TableInsertTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(
diff --git a/test/selenium/TableOperationsTest.php b/test/selenium/TableOperationsTest.php
index 0ea691dee1..30dbd85651 100644
--- a/test/selenium/TableOperationsTest.php
+++ b/test/selenium/TableOperationsTest.php
@@ -24,7 +24,7 @@ class TableOperationsTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
 
diff --git a/test/selenium/TableStructureTest.php b/test/selenium/TableStructureTest.php
index 2dde75949b..2575670187 100644
--- a/test/selenium/TableStructureTest.php
+++ b/test/selenium/TableStructureTest.php
@@ -24,7 +24,7 @@ class TableStructureTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(
diff --git a/test/selenium/TrackingTest.php b/test/selenium/TrackingTest.php
index 1dd128b8d8..9c094da4a9 100644
--- a/test/selenium/TrackingTest.php
+++ b/test/selenium/TrackingTest.php
@@ -24,7 +24,7 @@ class TrackingTest extends TestBase
      *
      * @return void
      */
-    public function setUp()
+    protected function setUp()
     {
         parent::setUp();
         $this->dbQuery(