From ffc6bbed7c03d985d114a038637067b133b22026 Mon Sep 17 00:00:00 2001 From: Michal Kleiner Date: Fri, 20 Dec 2019 11:14:30 +1300 Subject: [PATCH] Adjust $cascade_delete related tests so that the term stays in all stages --- tests/TaxonomyTermTest.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/TaxonomyTermTest.php b/tests/TaxonomyTermTest.php index 6fb0bf6..b789792 100644 --- a/tests/TaxonomyTermTest.php +++ b/tests/TaxonomyTermTest.php @@ -496,9 +496,9 @@ public function testOwnerObjectOwnsTaxonomyTerm() $object1FromLive = OwnerObject::get()->byID($object1->ID); $this->assertNull($object1FromLive, 'object1 doesn\'t exist on Live table after being unpublished'); $rootTerm1FromLive = TaxonomyTerm::get()->byID($rootTerm1->ID); - $this->assertNull( + $this->assertNotNull( $rootTerm1FromLive, - 'rootTerm1 doesn\'t exist on Live table after object1 being unpublished' + 'rootTerm1 still exists on Live after object1 being unpublished' ); $object1->doArchive(); @@ -506,9 +506,9 @@ public function testOwnerObjectOwnsTaxonomyTerm() $object1FromStage = OwnerObject::get()->byID($object1->ID); $this->assertNull($object1FromStage, 'object1 doesn\'t exist on Stage table after being archived'); $rootTerm1FromStage = TaxonomyTerm::get()->byID($rootTerm1->ID); - $this->assertNull( + $this->assertNotNull( $rootTerm1FromStage, - 'rootTerm1 doesn\'t exist on Stage table after object1 being archived' + 'rootTerm1 still exists on Stage after object1 being archived' ); // Restore the orig archived stage