public function testAddRemoveMatch() { $termType = new KVDthes_TermType('PT', 'voorkeursterm'); $term2 = new KVDthes_TestTerm(508, $this->sessie, 'kapellen', $termType, 'bouwkundig erfgoed'); $this->object->setLoadState(KVDthes_Matchable::LS_MATCH); $term2->setLoadState(KVDthes_Term::LS_REL); $term2->setLoadState(KVDthes_Term::LS_MATCH); $term2->setLoadState(KVDthes_Term::LS_NOTES); $this->object->addMatch(new KVDthes_Match(KVDthes_Match::MATCH_RM, $term2)); $this->assertEquals(1, count($this->object->getMatches())); $term2->removeMatch(new KVDthes_Match(KVDthes_Match::MATCH_RM, $this->object)); $this->assertEquals(0, count($this->object->getMatches())); }