/** * Applies the change to the fingerprint * * @param Fingerprint $fingerprint */ private function updateFingerprint(Fingerprint $fingerprint) { if ($this->description === null) { $fingerprint->removeDescription($this->languageCode); } else { $fingerprint->getDescriptions()->setTextForLanguage($this->languageCode, $this->description); } }
/** * @expectedException OutOfBoundsException */ public function testRemoveDescriptionMakesGetterThrowException() { $this->fingerprint->removeDescription('en'); $this->fingerprint->getDescription('en'); }