'2020-10-25 00:00:00', 'end_period' => '2020-10-25 08:00:00', 'name' => 'Riga, Winter, big zoom' ] ], [ [ 'start_period' => '2020-03-29 00:00:00', 'end_period' => '2020-03-29 08:00:00', 'name' => 'Riga, Summer, big zoom' ] ], [ [ 'start_period' => '2020-10-25 03:00:00', 'end_period' => '2020-10-25 05:00:00', 'name' => 'Riga, Winter, small zoom' ] ], [ [ 'start_period' => '2020-03-29 02:00:00', 'end_period' => '2020-03-29 04:00:00', 'name' => 'Riga, Summer, small zoom' ] ] ]; } /** * Test for checking X axis on graphs in default time zone depending on daylight saving changes. * * @dataProvider getDaylightSavingData */ public function testGraphAxis_DaylightSaving($data) { // Go to Graphs and set time period. $this->page->login()->open('zabbix.php?action=host.view')->waitUntilReady(); $table = $this->query('xpath://form[@name="host_view"]/table[@class="list-table"]') ->waitUntilReady()->asTable()->one(); $table->findRow('Name', 'Dynamic widgets H2')->getColumn('Graphs')->click(); $this->page->waitUntilReady(); $this->query('id:from')->one()->fill($data['start_period']); $this->query('id:to')->one()->fill($data['end_period']); $this->query('button:Apply')->one()->waitUntilClickable()->click(); try { $this->query('xpath://div[contains(@class,"is-loading")]/img')->waitUntilPresent(); } catch (\Exception $ex) { // Code is not missing here. } $this->assertScreenshot($this->query('xpath://div[not(contains(@class,"is-loading"))]/img')->waitUntilPresent() ->one(), $data['name']); } }