diff options
author | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-02-11 17:44:47 +0000 |
---|---|---|
committer | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-02-11 17:44:47 +0000 |
commit | 7562a8efb36306e96bf4d13b1f97b4573809ab45 (patch) | |
tree | 998dfd1d27d9c1a691a83a0c0e37d783d4fc4a44 /modules/simpletest | |
parent | 52195a6b1dd478875a93935df27d7bcacb14f289 (diff) | |
download | brdo-7562a8efb36306e96bf4d13b1f97b4573809ab45.tar.gz brdo-7562a8efb36306e96bf4d13b1f97b4573809ab45.tar.bz2 |
#707724 by chx: Rename confusing arguments in field/entity APIs.
Diffstat (limited to 'modules/simpletest')
-rw-r--r-- | modules/simpletest/tests/common.test | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/modules/simpletest/tests/common.test b/modules/simpletest/tests/common.test index 6c617edf7..7b64d46c4 100644 --- a/modules/simpletest/tests/common.test +++ b/modules/simpletest/tests/common.test @@ -24,8 +24,8 @@ class DrupalAlterTestCase extends DrupalWebTestCase { function testDrupalAlter() { $array = array('foo' => 'bar'); - $object = new stdClass; - $object->foo = 'bar'; + $entity = new stdClass; + $entity->foo = 'bar'; // Verify alteration of a single argument. $array_copy = $array; @@ -33,23 +33,23 @@ class DrupalAlterTestCase extends DrupalWebTestCase { drupal_alter('drupal_alter', $array_copy); $this->assertEqual($array_copy, $array_expected, t('Single array was altered.')); - $object_copy = clone $object; - $object_expected = clone $object; - $object_expected->foo = 'Drupal theme'; - drupal_alter('drupal_alter', $object_copy); - $this->assertEqual($object_copy, $object_expected, t('Single object was altered.')); + $entity_copy = clone $entity; + $entity_expected = clone $entity; + $entity_expected->foo = 'Drupal theme'; + drupal_alter('drupal_alter', $entity_copy); + $this->assertEqual($entity_copy, $entity_expected, t('Single object was altered.')); // Verify alteration of multiple arguments. $array_copy = $array; $array_expected = array('foo' => 'Drupal theme'); - $object_copy = clone $object; - $object_expected = clone $object; - $object_expected->foo = 'Drupal theme'; + $entity_copy = clone $entity; + $entity_expected = clone $entity; + $entity_expected->foo = 'Drupal theme'; $array2_copy = $array; $array2_expected = array('foo' => 'Drupal theme'); - drupal_alter('drupal_alter', $array_copy, $object_copy, $array2_copy); + drupal_alter('drupal_alter', $array_copy, $entity_copy, $array2_copy); $this->assertEqual($array_copy, $array_expected, t('First argument to drupal_alter() was altered.')); - $this->assertEqual($object_copy, $object_expected, t('Second argument to drupal_alter() was altered.')); + $this->assertEqual($entity_copy, $entity_expected, t('Second argument to drupal_alter() was altered.')); $this->assertEqual($array2_copy, $array2_expected, t('Third argument to drupal_alter() was altered.')); } } |