Search in sources :

Example 1 with EntryPartWriterXLS

use of org.nextprot.api.core.export.EntryPartWriterXLS in project nextprot-api by calipho-sib.

the class EntryPartWriterXLSTest method getExpressionProfileOutputString.

@Test
public void getExpressionProfileOutputString() throws Exception {
    File tempFile = testFolder.newFile("out.xls");
    OutputStream fos = new FileOutputStream(tempFile);
    String subpart = "expression-profile";
    Entry entry = entryBuilderService.build(EntryConfig.newConfig("NX_P01308").with(subpart));
    EntryPartWriterXLS writer = new EntryPartWriterXLS(EntryPartExporterImpl.fromSubPart(subpart), fos);
    writer.write(entry);
    fos.close();
    assertCountsEquals(571, 13, tempFile);
}
Also used : Entry(org.nextprot.api.core.domain.Entry) EntryPartWriterXLS(org.nextprot.api.core.export.EntryPartWriterXLS) CoreUnitBaseTest(org.nextprot.api.core.test.base.CoreUnitBaseTest) Test(org.junit.Test)

Aggregations

Test (org.junit.Test)1 Entry (org.nextprot.api.core.domain.Entry)1 EntryPartWriterXLS (org.nextprot.api.core.export.EntryPartWriterXLS)1 CoreUnitBaseTest (org.nextprot.api.core.test.base.CoreUnitBaseTest)1