### Question:
DateDisplay { int getStyle(String style) { int formatType = -1; if("long".equals(style)) { formatType = DateFormat.LONG; } else if("medium".equals(style)) { formatType = DateFormat.MEDIUM; } else if("full".equals(style)) { formatType = DateFormat.FULL; } else if("short".equals(style)) { formatType = DateFormat.SHORT; } return formatType; } DateDisplay();   DateDisplay(String format, Date value, Locale locale);   }### Answer:
@Test public void test_get_style_works_for_styles() { DateDisplay component = new DateDisplay(); assertEquals(component.getStyle("long"), DateFormat.LONG); assertEquals(component.getStyle("short"), DateFormat.SHORT); assertEquals(component.getStyle("full"), DateFormat.FULL); assertEquals(component.getStyle("medium"), DateFormat.MEDIUM); }