aboutsummaryrefslogtreecommitdiffstats
path: root/tests/test_framework/phpbb_test_case.php
diff options
context:
space:
mode:
authorNils Adermann <naderman@naderman.de>2010-10-22 19:11:18 +0200
committerNils Adermann <naderman@naderman.de>2010-10-25 19:38:35 +0200
commitee846c461c6f0d4ec02dcefa6c82090587bc7012 (patch)
tree7d474e0744a170b92df96329ca2580fdc4ca988c /tests/test_framework/phpbb_test_case.php
parentd503272645d0f14daa2c2664e04dbdc33da9379e (diff)
downloadforums-ee846c461c6f0d4ec02dcefa6c82090587bc7012.tar
forums-ee846c461c6f0d4ec02dcefa6c82090587bc7012.tar.gz
forums-ee846c461c6f0d4ec02dcefa6c82090587bc7012.tar.bz2
forums-ee846c461c6f0d4ec02dcefa6c82090587bc7012.tar.xz
forums-ee846c461c6f0d4ec02dcefa6c82090587bc7012.zip
[task/mssql-db-tests] Use a simple getter for test case helpers.
Calling initialisation to then use the member directly seems more complicated than just having a method that returns the instance or creates it if necessary. PHPBB3-9868
Diffstat (limited to 'tests/test_framework/phpbb_test_case.php')
-rw-r--r--tests/test_framework/phpbb_test_case.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/test_framework/phpbb_test_case.php b/tests/test_framework/phpbb_test_case.php
index af867b29ff..fe90d321dc 100644
--- a/tests/test_framework/phpbb_test_case.php
+++ b/tests/test_framework/phpbb_test_case.php
@@ -11,17 +11,18 @@ class phpbb_test_case extends PHPUnit_Framework_TestCase
{
protected $test_case_helpers;
- public function init_test_case_helpers()
+ public function get_test_case_helpers()
{
if (!$this->test_case_helpers)
{
$this->test_case_helpers = new phpbb_test_case_helpers($this);
}
+
+ return $this->test_case_helpers;
}
public function setExpectedTriggerError($errno, $message = '')
{
- $this->init_test_case_helpers();
- $this->test_case_helpers->setExpectedTriggerError($errno, $message);
+ $this->get_test_case_helpers()->setExpectedTriggerError($errno, $message);
}
}