diff options
author | Marc Alexander <admin@m-a-styles.de> | 2019-10-03 11:06:58 +0200 |
---|---|---|
committer | Marc Alexander <admin@m-a-styles.de> | 2019-10-03 11:06:58 +0200 |
commit | 1eed2f98c30210d02b8ca3bf5b167fae67dc64dd (patch) | |
tree | 7364da57623f9bb48fe25a9dccc80426040a73e7 /tests/functional/extension_acp_test.php | |
parent | b6c230753ee17fe65b43929d4fc10248ea2a23bf (diff) | |
parent | e54aa94e7714483f0f5ef8c18e21317a1f0524f6 (diff) | |
download | forums-1eed2f98c30210d02b8ca3bf5b167fae67dc64dd.tar forums-1eed2f98c30210d02b8ca3bf5b167fae67dc64dd.tar.gz forums-1eed2f98c30210d02b8ca3bf5b167fae67dc64dd.tar.bz2 forums-1eed2f98c30210d02b8ca3bf5b167fae67dc64dd.tar.xz forums-1eed2f98c30210d02b8ca3bf5b167fae67dc64dd.zip |
Merge pull request #5555 from senky/ticket/15257
[ticket/15257] Provide extension not enableable messages
Diffstat (limited to 'tests/functional/extension_acp_test.php')
-rw-r--r-- | tests/functional/extension_acp_test.php | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/tests/functional/extension_acp_test.php b/tests/functional/extension_acp_test.php index b398a73e3f..9a326dba68 100644 --- a/tests/functional/extension_acp_test.php +++ b/tests/functional/extension_acp_test.php @@ -86,7 +86,7 @@ class phpbb_functional_extension_acp_test extends phpbb_functional_test_case $crawler = self::request('GET', 'adm/index.php?i=acp_extensions&mode=main&sid=' . $this->sid); $this->assertCount(1, $crawler->filter('.ext_enabled')); - $this->assertCount(6, $crawler->filter('.ext_disabled')); + $this->assertCount(7, $crawler->filter('.ext_disabled')); $this->assertContains('phpBB Foo Extension', $crawler->filter('.ext_enabled')->eq(0)->text()); $this->assertContainsLang('EXTENSION_DISABLE', $crawler->filter('.ext_enabled')->eq(0)->text()); @@ -165,9 +165,14 @@ class phpbb_functional_extension_acp_test extends phpbb_functional_test_case $crawler = self::request('GET', 'adm/index.php?i=acp_extensions&mode=main&action=enable_pre&ext_name=vendor%2Fmoo&sid=' . $this->sid); $this->assertContains($this->lang('EXTENSION_ENABLE_CONFIRM', 'phpBB Moo Extension'), $crawler->filter('#main')->text()); - // Correctly submit the enable form + // Correctly submit the enable form, default not enableable message $crawler = self::request('GET', 'adm/index.php?i=acp_extensions&mode=main&action=enable_pre&ext_name=vendor3%2Ffoo&sid=' . $this->sid); $this->assertContainsLang('EXTENSION_NOT_ENABLEABLE', $crawler->filter('.errorbox')->text()); + + // Custom reason messages returned by not enableable extension + $crawler = self::request('GET', 'adm/index.php?i=acp_extensions&mode=main&action=enable_pre&ext_name=vendor5%2Ffoo&sid=' . $this->sid); + $this->assertContains('Reason 1', $crawler->filter('.errorbox')->text()); + $this->assertContains('Reason 2', $crawler->filter('.errorbox')->text()); } public function test_disable_pre() |