public function testFindAddonForRecordExhibitPage()
 {
     $mgr = new SolrSearch_Addon_Manager($this->db);
     $mgr->parseAll();
     $addon = $mgr->findAddonForRecord($this->_exhibitPage());
     $this->assertNotNull($addon);
     $this->assertEquals('exhibit_pages', $addon->name);
 }
 /**
  * Get the key used on Solr documents for a field on a given record.
  *
  * @param Omeka_Record_AbstractRecord $record The record.
  * @param string $field The field.
  * @return string
  */
 protected function _getAddonKey($record, $field)
 {
     // Spin up a manager and indexer.
     $mgr = new SolrSearch_Addon_Manager($this->db);
     $idx = new SolrSearch_Addon_Indexer($this->db);
     $mgr->parseAll();
     // Return the key used to store the field on the Solr document.
     return $idx->makeSolrName($mgr->findAddonForRecord($record), $field);
 }