From c9d4cf5b0b0f5ad3056cd4d6dc744a8b4890fb4e Mon Sep 17 00:00:00 2001 From: brettp Date: Mon, 14 Feb 2011 03:40:59 +0000 Subject: Updated trunk to use new annotation functions. Added checks for annotations_* options vs annotation_* options because it's so easy to confuse. git-svn-id: http://code.elgg.org/elgg/trunk@8223 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/tests/api/entity_getter_functions.php | 4 ++-- engine/tests/api/metastrings.php | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'engine/tests/api') diff --git a/engine/tests/api/entity_getter_functions.php b/engine/tests/api/entity_getter_functions.php index e3e265d21..1633cbe19 100644 --- a/engine/tests/api/entity_getter_functions.php +++ b/engine/tests/api/entity_getter_functions.php @@ -239,7 +239,7 @@ class ElggCoreEntityGetterFunctionsTest extends ElggCoreUnitTest { $name = 'test_annotation_name_' . rand(); $value = rand(); $id = create_annotation($entity->getGUID(), $name, $value, 'integer', $entity->getGUID()); - $annotations[] = get_annotation($id); + $annotations[] = elgg_get_annotation_from_id($id); } return $annotations; @@ -2772,7 +2772,7 @@ class ElggCoreEntityGetterFunctionsTest extends ElggCoreUnitTest { } while(in_array($e->guid, $a_e_map)); // remove annotations left over from previous tests. - clear_annotations($e->guid); + elgg_delete_annotations(array('annotation_owner_guid' => $e->guid)); $annotations = $this->createRandomAnnotations($e); foreach($annotations as $a) { diff --git a/engine/tests/api/metastrings.php b/engine/tests/api/metastrings.php index 9d089f804..e5cfe80e1 100644 --- a/engine/tests/api/metastrings.php +++ b/engine/tests/api/metastrings.php @@ -88,14 +88,14 @@ class ElggCoreMetastringsTest extends ElggCoreUnitTest { } } - public function testGetMetastringObjectByID() { + public function testGetMetastringObjectFromID() { $db_prefix = elgg_get_config('dbprefix'); $annotations = $this->createAnnotations(1); $metadata = $this->createMetadata(1); foreach ($this->metastringTypes as $type) { $id = ${$type}[0]; - $test = elgg_get_metastring_based_object_by_id($id, $type); + $test = elgg_get_metastring_based_object_from_id($id, $type); $this->assertEqual($id, $test->id); } -- cgit v1.2.3