require_once dirname(__FILE__).'/common/testFormAdministrationGeneral.php';
class testFormAdministrationGeneralGUI extends testFormAdministrationGeneral {
public $config_link = 'zabbix.php?action=gui.edit';
public $form_selector = 'xpath://form[contains(@action, "gui.update")]';
public $default_values = [
'Default language' => 'English (en_US)',
'Default time zone' => 'System',
'Default theme' => 'Blue',
'Limit for search and filter results' => '1000',
'Max number of columns and rows in overview tables' => '50',
'Max count of elements to show inside table cell' => '50',
'Show warning if Zabbix server is down' => true,
'Working time' => '1-5,09:00-18:00',
'Show technical errors' => false,
'Max history display period' => '24h',
'Time filter default period' => '1h',
'Max period for time selector' => '2y'
public $db_default_values = [
'default_lang' => 'en_US',
'default_timezone' => 'system',
'default_theme' => 'blue-theme',
'max_overview_table_size' => 50,
'server_check_interval' => 10,
'work_period' => '1-5,09:00-18:00',
'show_technical_errors' => 0,
'history_period' => '24h',
'period_default' => '1h',
public $custom_values = [
'Default language' => 'English (en_US)',
'Default theme' => 'Dark',
'Limit for search and filter results' => '50',
'Max number of columns and rows in overview tables' => '25',
'Max count of elements to show inside table cell' => '100',
'Show warning if Zabbix server is down' => false,
'Working time' => '1-3,03:15-22:45',
'Show technical errors' => true,
'Max history display period' => '24h',
'Time filter default period' => '1h',
'Max period for time selector' => '2y'
public function testFormAdministrationGeneralGUI_CheckLayout() {
$this->page->login()->open('zabbix.php?action=gui.edit');
$this->page->assertTitle('Configuration of GUI');
$this->page->assertHeader('GUI');
'max_overview_table_size' => 6,
foreach ($limits as $id => $limit) {
$this->assertEquals($limit, $this->query('id', $id)->one()->getAttribute('maxlength'));