@Test public void testGetInfraspecificMarker() throws Exception { @SuppressWarnings("unchecked") CSVRecordInfo<BrahmsCsvField> record = mock(CSVRecordInfo.class); ScientificName expected = new ScientificName(); when(record.get(SPECIES)).thenReturn("Rhododendron ferrugineum L."); when(record.get(AUTHOR2)).thenReturn("L."); when(record.get(GENUS)).thenReturn("Rhododendron"); when(record.get(SP1)).thenReturn("ferrugineum"); when(record.get(RANK2)).thenReturn("testInfraSpecifc"); when(record.get(SP2)).thenReturn(""); expected = BrahmsImportUtil.getScientificName(record); assertNotNull("01",expected); assertEquals("02","testInfraSpecifc", expected.getInfraspecificMarker()); }
public static String getInfraspecificMarker(CSVRecordInfo<BrahmsCsvField> record) { String s = record.get(RANK2); return s == null ? record.get(RANK1) : s; }
BrahmsImportUtil { public static String getInfraspecificMarker(CSVRecordInfo<BrahmsCsvField> record) { String s = record.get(RANK2); return s == null ? record.get(RANK1) : s; } }
BrahmsImportUtil { public static String getInfraspecificMarker(CSVRecordInfo<BrahmsCsvField> record) { String s = record.get(RANK2); return s == null ? record.get(RANK1) : s; } BrahmsImportUtil(); }
BrahmsImportUtil { public static String getInfraspecificMarker(CSVRecordInfo<BrahmsCsvField> record) { String s = record.get(RANK2); return s == null ? record.get(RANK1) : s; } BrahmsImportUtil(); static File[] getCsvFiles(); static void backup(); static void removeBackupExtension(); static ScientificName getScientificName(CSVRecordInfo<BrahmsCsvField> record); static DefaultClassification getDefaultClassification(CSVRecordInfo<BrahmsCsvField> record,
			ScientificName sn); static List<Monomial> getSystemClassification(DefaultClassification dc); static String getAuthor(CSVRecordInfo<BrahmsCsvField> record); static String getInfraspecificMarker(CSVRecordInfo<BrahmsCsvField> record); static String getInfraspecificEpithet(CSVRecordInfo<BrahmsCsvField> record); static String getTaxonRank(CSVRecordInfo<BrahmsCsvField> record); static File getDataDir(); }
BrahmsImportUtil { public static String getInfraspecificMarker(CSVRecordInfo<BrahmsCsvField> record) { String s = record.get(RANK2); return s == null ? record.get(RANK1) : s; } BrahmsImportUtil(); static File[] getCsvFiles(); static void backup(); static void removeBackupExtension(); static ScientificName getScientificName(CSVRecordInfo<BrahmsCsvField> record); static DefaultClassification getDefaultClassification(CSVRecordInfo<BrahmsCsvField> record,
			ScientificName sn); static List<Monomial> getSystemClassification(DefaultClassification dc); static String getAuthor(CSVRecordInfo<BrahmsCsvField> record); static String getInfraspecificMarker(CSVRecordInfo<BrahmsCsvField> record); static String getInfraspecificEpithet(CSVRecordInfo<BrahmsCsvField> record); static String getTaxonRank(CSVRecordInfo<BrahmsCsvField> record); static File getDataDir();  }