summaryrefslogtreecommitdiff
path: root/modules/simpletest/simpletest.test
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2008-11-26 13:48:50 +0000
committerDries Buytaert <dries@buytaert.net>2008-11-26 13:48:50 +0000
commit63e195eb3024e9aa79c1c4bc7285b329329c91af (patch)
tree1c8c68ca5e842357a0103cf9f721cb668aa33c6f /modules/simpletest/simpletest.test
parent6e5851b3a932340a282b2cfc3187935fe52b1faf (diff)
downloadbrdo-63e195eb3024e9aa79c1c4bc7285b329329c91af.tar.gz
brdo-63e195eb3024e9aa79c1c4bc7285b329329c91af.tar.bz2
- Patch #338239 by Damien Tournoud: clean-up DrupalWebTestCase.
Diffstat (limited to 'modules/simpletest/simpletest.test')
-rw-r--r--modules/simpletest/simpletest.test10
1 files changed, 5 insertions, 5 deletions
diff --git a/modules/simpletest/simpletest.test b/modules/simpletest/simpletest.test
index 19278f23c..ce1cb2a98 100644
--- a/modules/simpletest/simpletest.test
+++ b/modules/simpletest/simpletest.test
@@ -5,7 +5,7 @@ class SimpleTestTestCase extends DrupalWebTestCase {
/**
* The results array that has been parsed by getTestResults().
*/
- protected $results;
+ protected $childTestResults;
/**
* Store the test ID from each test run for comparison, to ensure they are
@@ -100,7 +100,7 @@ class SimpleTestTestCase extends DrupalWebTestCase {
$this->drupalCreateUser(array($this->valid_permission));
$this->drupalCreateUser(array($this->invalid_permission));
- $this->pass(t('Test ID is @id.', array('@id' => $this->test_id)));
+ $this->pass(t('Test ID is @id.', array('@id' => $this->testId)));
// Generates a warning.
$i = 1 / 0;
@@ -146,7 +146,7 @@ class SimpleTestTestCase extends DrupalWebTestCase {
* Fetch the test id from the test results.
*/
function getTestIdFromResults() {
- foreach($this->results['assertions'] as $assertion) {
+ foreach($this->childTestResults['assertions'] as $assertion) {
if (preg_match('@^Test ID is ([0-9]*)\.$@', $assertion['message'], $matches)) {
return $matches[1];
}
@@ -168,7 +168,7 @@ class SimpleTestTestCase extends DrupalWebTestCase {
function assertAssertion($message, $type, $status, $file, $function) {
$message = trim(strip_tags($message));
$found = FALSE;
- foreach ($this->results['assertions'] as $assertion) {
+ foreach ($this->childTestResults['assertions'] as $assertion) {
if ((strpos($assertion['message'], $message) !== FALSE) &&
$assertion['type'] == $type &&
$assertion['status'] == $status &&
@@ -208,7 +208,7 @@ class SimpleTestTestCase extends DrupalWebTestCase {
}
}
}
- $this->results = $results;
+ $this->childTestResults = $results;
}
/**