diff --git a/eu_basynthec/dist/etc/transcriptomics/data-set-handler.py b/eu_basynthec/dist/etc/transcriptomics/data-set-handler.py index 1b7eb9a5f794eb5370cabcdcbb7f323742f2a807..dde79f935c0cdbfdee1cd825460eeba62fd2bb56 100644 --- a/eu_basynthec/dist/etc/transcriptomics/data-set-handler.py +++ b/eu_basynthec/dist/etc/transcriptomics/data-set-handler.py @@ -3,7 +3,7 @@ from eu.basynthec.cisd.dss import TimeSeriesDataExcel import re # A Regex for matching the column headers -header_regex = re.compile("^(.+)-([0-9]) ([0-9]+)") +header_regex = re.compile("^(.+)-(.*) ([0-9]+)") def set_data_type(data_set): data_set.setPropertyValue("DATA_TYPE", "TRANSCRIPTOMICS") diff --git a/eu_basynthec/dist/etc/transcriptomics/data-set-validator.py b/eu_basynthec/dist/etc/transcriptomics/data-set-validator.py index ad62da996232b75a1e8323011bc24a7c3c8eca0b..71c191ff26efec0c75d79ab5c8e701e74f61ab15 100644 --- a/eu_basynthec/dist/etc/transcriptomics/data-set-validator.py +++ b/eu_basynthec/dist/etc/transcriptomics/data-set-validator.py @@ -3,7 +3,7 @@ def validate_header(line, first_data_col, errors): if line[0] != "Locustag": errors.append(createFileValidationError("The first data column must be 'Locustag' (not " + line[0] + ").")) return False - header_regex = re.compile("^(.+)-([0-9]) ([0-9]+)") + header_regex = re.compile("^(.+)-(.*) ([0-9]+)") for i in range(first_data_col, len(line)): match = header_regex.match(line[i]) if match is None: diff --git a/eu_basynthec/sourceTest/java/eu/basynthec/cisd/dss/TimeSeriesDataExcelTest.java b/eu_basynthec/sourceTest/java/eu/basynthec/cisd/dss/TimeSeriesDataExcelTest.java index d22754f6cd638b77f43bd13bb588393b126d1fa7..d5e444026b34b3438248c1b4df53772833172e7b 100644 --- a/eu_basynthec/sourceTest/java/eu/basynthec/cisd/dss/TimeSeriesDataExcelTest.java +++ b/eu_basynthec/sourceTest/java/eu/basynthec/cisd/dss/TimeSeriesDataExcelTest.java @@ -102,11 +102,11 @@ public class TimeSeriesDataExcelTest extends AssertJUnit String[][] expectedData = { { "Strain", "HumanReadable", "-19020.0", "-17220.0" }, - { "JJS-MGP1", "OD600", "0.05", "0.064" }, + { "JJS-MGP001", "OD600", "0.05", "0.064" }, { "JJS-MGP100", "OD600", "0.05", "0.064" }, - { "JJS-MGP20", "OD600", "0.05", "0.064" }, + { "JJS-MGP020", "OD600", "0.05", "0.064" }, { "JJS-MGP999", "OD600", "0.05", "0.064" }, - { "JJS-MGP1", "OD600", "0.05", "0.064" }, + { "JJS-MGP001", "OD600", "0.05", "0.064" }, { "MS", "OD600", "0.05", "0.064" }, { "WT 168 trp+", "OD600", "0.05", "0.064" } }; assertLinesAreEqual(dataLines, expectedData); diff --git a/eu_basynthec/sourceTest/java/eu/basynthec/cisd/dss/growthprofiles/OD600DataSetRegistratorTest.java b/eu_basynthec/sourceTest/java/eu/basynthec/cisd/dss/growthprofiles/OD600DataSetRegistratorTest.java index 79228aa0874563ded1195c374bcd41c9992626dc..362cfa5324051c801a42d18f4b3636e9d01fa549 100644 --- a/eu_basynthec/sourceTest/java/eu/basynthec/cisd/dss/growthprofiles/OD600DataSetRegistratorTest.java +++ b/eu_basynthec/sourceTest/java/eu/basynthec/cisd/dss/growthprofiles/OD600DataSetRegistratorTest.java @@ -82,10 +82,12 @@ public class OD600DataSetRegistratorTest extends AbstractBaSynthecDataSetRegistr String[] contents = tsvSplitFolder.list(); Arrays.sort(contents); String[] expectedContents = - { "OD600-Example.xlsx_JJS-MGP1.tsv", "OD600-Example.xlsx_JJS-MGP100.tsv", - "OD600-Example.xlsx_JJS-MGP20.tsv", "OD600-Example.xlsx_JJS-MGP999.tsv", "OD600-Example.xlsx_MS.tsv", "OD600-Example.xlsx_WT 168 trp+.tsv" }; + { "OD600-Example.xlsx_JJS-MGP001.tsv", "OD600-Example.xlsx_JJS-MGP020.tsv", + "OD600-Example.xlsx_JJS-MGP100.tsv", + "OD600-Example.xlsx_JJS-MGP999.tsv", "OD600-Example.xlsx_MS.tsv", + "OD600-Example.xlsx_WT 168 trp+.tsv" }; assertEquals(Arrays.asList(expectedContents), Arrays.asList(contents)); - File tsvSplitFile = new File(tsvSplitFolder, "OD600-Example.xlsx_JJS-MGP1.tsv"); + File tsvSplitFile = new File(tsvSplitFolder, "OD600-Example.xlsx_JJS-MGP001.tsv"); checkTsvSplitContent(tsvSplitFile); context.assertIsSatisfied();