Class ArrayDesignAnnotationServiceImplTest
java.lang.Object
ubic.gemma.core.analysis.service.ArrayDesignAnnotationServiceImplTest
@ExtendWith(org.mockito.junit.jupiter.MockitoExtension.class)
public class ArrayDesignAnnotationServiceImplTest
extends Object
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcreate_whenGenerationFails_keepsThePreviousFile(Path annotDataDir) The previous annotation file was deleted before the new one was written in place, so a failure midway left a truncated file that was still valid gzip, and it was served as the platform's annotations.voidA GO association whose URI is not in the loaded ontology makesGeneOntologyService.getTerm(String)return null.
-
Constructor Details
-
ArrayDesignAnnotationServiceImplTest
public ArrayDesignAnnotationServiceImplTest()
-
-
Method Details
-
generateAnnotationFile_whenATermIsNotInTheLoadedOntology_writesTheRemainingTerms
@Test public void generateAnnotationFile_whenATermIsNotInTheLoadedOntology_writesTheRemainingTerms() throws ExceptionA GO association whose URI is not in the loaded ontology makesGeneOntologyService.getTerm(String)return null. Collecting that null used to hand it straight toGeneOntologyUtils.asRegularGoId(OntologyTerm)(and, for the LONG output type, togetAllParents), which dereference every element — so a single unresolvable term aborted the whole annotation file with a bare NullPointerException.- Throws:
Exception
-
create_whenGenerationFails_keepsThePreviousFile
@Test public void create_whenGenerationFails_keepsThePreviousFile(@TempDir Path annotDataDir) throws Exception The previous annotation file was deleted before the new one was written in place, so a failure midway left a truncated file that was still valid gzip, and it was served as the platform's annotations.- Throws:
Exception
-