### Question:
EventHelper { public static String getEventCode(String matchOrEventOrDistrictKey) { Matcher m = EVENT_KEY_PATTERN.matcher(matchOrEventOrDistrictKey); return m.find() ? m.group().toUpperCase(Locale.US) : ""; } private  EventHelper(); static boolean validateEventKey(String key); static String shortName(String eventName); static int getYear(String eventKey); static int getYearWeek(Date date); static int competitionWeek(Date date); static String generateLabelForEvent(Event e); static String weekLabelFromNum(int year, @Nullable Integer weekNum); static int weekNumFromLabel(int year, String label); static void renderEventListForTeam(Context context,List<Event> events, List<Object> output); static void renderEventListForWeek(Context context, List<Event> events, List<Object> output); static void renderEventListForDistrict(
            Context context,
            List<Event> events,
            List<Object> output); static String getDateString(Date startDate, Date endDate); static String getShortCodeForEventKey(String eventKey); static String getEventCode(String matchOrEventOrDistrictKey); static final String CHAMPIONSHIP_LABEL; static final String CITY_CHAMPIONSHIP_LABEL; static final String REGIONAL_LABEL; static final String FLOAT_REGIONAL_LABEL; static final String WEEKLESS_LABEL; static final String OFFSEASON_LABEL; static final String PRESEASON_LABEL; }### Answer:
@Test public void testGetEventCode() { assertEquals("CTHAR", EventHelper.getEventCode("2015cthar")); assertEquals("NYNY", EventHelper.getEventCode("2015NYNY")); assertEquals("DCVA", EventHelper.getEventCode("2015dcva_f1m1")); assertEquals("CTWAT", EventHelper.getEventCode("2015ctwat_frc1124")); }