summaryrefslogtreecommitdiff
path: root/modules/taxonomy/taxonomy.test
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2008-12-04 10:57:17 +0000
committerDries Buytaert <dries@buytaert.net>2008-12-04 10:57:17 +0000
commitdc82bc5ab0a3a58efa3946602ba75a0ed05e2311 (patch)
treeae32ebed8a3af922e9bb60d640118d268c7de892 /modules/taxonomy/taxonomy.test
parent424aaef46cf5cfbbb404d596288f0e1425259be2 (diff)
downloadbrdo-dc82bc5ab0a3a58efa3946602ba75a0ed05e2311.tar.gz
brdo-dc82bc5ab0a3a58efa3946602ba75a0ed05e2311.tar.bz2
- Patch #341872 by mayer, catch: fixed bug in database conversion and added a missing test for taxonomy_term_save().
Diffstat (limited to 'modules/taxonomy/taxonomy.test')
-rw-r--r--modules/taxonomy/taxonomy.test9
1 files changed, 8 insertions, 1 deletions
diff --git a/modules/taxonomy/taxonomy.test b/modules/taxonomy/taxonomy.test
index 4aa5cc9e7..bc85bbe68 100644
--- a/modules/taxonomy/taxonomy.test
+++ b/modules/taxonomy/taxonomy.test
@@ -268,9 +268,16 @@ class TaxonomyTermTestCase extends TaxonomyWebTestCase {
$edit = array();
$edit['relations[]'] = $term2->tid;
$this->drupalPost('taxonomy/term/' . $term1->tid . '/edit', $edit, t('Save'));
-
$related = taxonomy_get_related($term1->tid);
$this->assertTrue(isset($related[$term2->tid]), t('Related term was found'));
+ // Create a third term.
+ $term3 = $this->createTerm($this->vocabulary->vid);
+ $edit['relations[]'] = $term3->tid;
+ $this->drupalPost('taxonomy/term/' . $term1->tid . '/edit', $edit, t('Save'));
+
+ $related = taxonomy_get_related($term1->tid);
+ $this->assertTrue(isset($related[$term3->tid]), t('Related term was found'));
+ $this->assertFalse(isset($related[$term2->tid]), t('Term relationship no longer exists'));
}
/**