mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-01 14:30:32 +02:00
[ticket/16549] Fix tests
PHPBB3-16549
This commit is contained in:
@@ -117,8 +117,10 @@ class phpbb_functional_acp_groups_test extends phpbb_functional_common_groups_te
|
||||
else
|
||||
{
|
||||
$this->form_data = $form->getValues();
|
||||
$this->assertEquals($tick_legend, $this->form_data['group_legend']);
|
||||
$this->assertEquals($tick_teampage, $this->form_data['group_teampage']);
|
||||
// form_data[] values can be bool or null if not ticked, $tick_* value can be bool or null if not set.
|
||||
// Cast both to the same type to correctly compare the values.
|
||||
$this->assertEquals((bool) $tick_legend, (bool) ($this->form_data['group_legend'] ?? false));
|
||||
$this->assertEquals((bool) $tick_teampage, (bool) ($this->form_data['group_teampage'] ?? false));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -80,6 +80,6 @@ class phpbb_functional_avatar_acp_groups_test extends phpbb_functional_common_av
|
||||
$crawler = self::request('GET', $this->get_url() . '&sid=' . $this->sid);
|
||||
$form = $crawler->selectButton($this->lang('SUBMIT'))->form();
|
||||
$form_data = $form->getValues();
|
||||
$this->assertEmpty($form_data['avatar_type']);
|
||||
$this->assertFalse(isset($form_data['avatar_type']));
|
||||
}
|
||||
}
|
||||
|
@@ -39,7 +39,7 @@ class phpbb_functional_smilies_test extends phpbb_functional_test_case
|
||||
$crawler = self::request('GET', 'posting.php?mode=smilies');
|
||||
foreach ($smilies as $index => $smiley)
|
||||
{
|
||||
$this->assertContains($smiley['smiley_url'],
|
||||
$this->assertStringContainsString($smiley['smiley_url'],
|
||||
$crawler->filter('div[class="inner"] > a > img')->eq($index)->attr('src')
|
||||
);
|
||||
}
|
||||
|
Reference in New Issue
Block a user