summaryrefslogtreecommitdiff
path: root/tests/MetaboxTest.php
diff options
context:
space:
mode:
authorDaniel Weipert <code@drogueronin.de>2020-12-16 22:07:02 +0100
committerDaniel Weipert <code@drogueronin.de>2020-12-16 22:07:02 +0100
commite3c2639e80665e623e1f1f4ce93fe80babb59f09 (patch)
tree6da034e5841b086083c779153abf65d48a4914a4 /tests/MetaboxTest.php
parent3195d4785e505f664898b6d5599c844832fa9734 (diff)
Adds Taxonomy Term Meta supportv1.1.0
Diffstat (limited to 'tests/MetaboxTest.php')
-rw-r--r--tests/MetaboxTest.php19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/MetaboxTest.php b/tests/MetaboxTest.php
index 1a1353e..e26c9f2 100644
--- a/tests/MetaboxTest.php
+++ b/tests/MetaboxTest.php
@@ -55,6 +55,25 @@ class MetaboxTest extends TestCase
/**
* @test
*/
+ public function assignsTaxonomyOnce()
+ {
+ $this->metabox->taxonomy(['category', 'post_tag']);
+
+ $expectedTaxonomies = [
+ 'category' => 'category',
+ 'post_tag' => 'post_tag',
+ ];
+
+ $this->assertEquals($expectedTaxonomies, $this->metabox->taxonomies);
+
+ $this->metabox->taxonomy('category');
+
+ $this->assertEquals($expectedTaxonomies, $this->metabox->taxonomies);
+ }
+
+ /**
+ * @test
+ */
public function modifiesAndHoldsPassedField()
{
$this->metabox->field($this->field);