Merge pull request #122 from webbuilders-group/unit-test-fix

BUGFIX: SolrVersionedTest_Index causing crash in unit tests when Phockito is not installed
This commit is contained in:
Damian Mooyman 2016-07-07 18:37:02 +12:00 committed by GitHub
commit c6c3d3c3ab

View File

@ -182,6 +182,22 @@ class SolrVersionedTest_Index extends SolrIndex
}
}
/**
* Non-sitetree versioned dataobject
*/
class SolrIndexVersionedTest_Object extends DataObject implements TestOnly {
private static $extensions = array(
'Versioned'
);
private static $db = array(
'Title' => 'Varchar',
'Content' => 'Text',
'TestText' => 'Varchar',
);
}
if (!class_exists('Phockito')) {
return;
}
@ -215,19 +231,3 @@ class SolrDocumentMatcher extends Hamcrest_BaseMatcher
return true;
}
}
/**
* Non-sitetree versioned dataobject
*/
class SolrIndexVersionedTest_Object extends DataObject implements TestOnly {
private static $extensions = array(
'Versioned'
);
private static $db = array(
'Title' => 'Varchar',
'Content' => 'Text',
'TestText' => 'Varchar',
);
}