### Question:
LMISConfiguration implements IConfiguration { public static List<ExcelCategory> getCategories(BufferedReader bufferedReader) throws IOException { List<ExcelCategory> categories = new ArrayList<ExcelCategory>(); String line; while ((line = bufferedReader.readLine()) != null) { String[] parts = line.split(","); String categoryName = parts[0]; String commodityName = parts[1]; String isNonLGAText = parts[2]; String isDeviceText = parts[3]; String isVaccineText = parts[4]; boolean isNonLGA = isNonLGAText.equalsIgnoreCase("1"); boolean isDevice = isDeviceText.equalsIgnoreCase("1"); boolean isVaccine = isVaccineText.equalsIgnoreCase("1"); ExcelCategory category = new ExcelCategory(categoryName); if (!categories.contains(category)) { categories.add(category); } categories.get(categories.indexOf(category)).getCommodityList().add( new ExcelCommodity(commodityName, isNonLGA, isDevice, isVaccine)); } return categories; } LMISConfiguration(CategoryCombo defaultCategoryCombo); @Override Map<String, Object> generateMetaData(); static List<ExcelCategory> getCategories(BufferedReader bufferedReader); static List<String> getCategoryNames(BufferedReader bufferedReader); static final String DATA_ELEMENTS; static final String DATA_ELEMENT_GROUPS; static final String DATA_ELEMENT_GROUP_SETS; static final String DATA_SETS; static final String OPTION_SETS; static final String INDICATOR_TYPES; static final String INDICATORS; static final String ATTRIBUTES; static final String CONSTANTS; static final String OPTIONS; }### Answer:
@Test public void shouldHaveSomeDevices() throws Exception { List<ExcelCategory> categories = getCategories(new BufferedReader(new FileReader("commodities.csv"))); for (ExcelCategory category : categories) { for (ExcelCommodity commodity : category.getCommodityList()) { if (commodity.getName().toLowerCase().contains("syringe")) { assertThat(commodity.isDevice(), is(true)); } else { assertThat(commodity.getName(), commodity.isDevice(), is(false)); } } } }