BrainkeyDictionaryManager { private BrainkeyDictionaryManager() throws IOException { FileReader fileReader = new FileReader(getClass().getClassLoader().getResource(DICTIONARY_FILE_NAME).getFile()); try { this.brainKeyDictionary = IOUtils.toString(fileReader).split(DICTIONARY_DELIMITER); } finally { fileReader.close(); } } private  BrainkeyDictionaryManager(); String[] getBrainKeyDictionary(); static BrainkeyDictionaryManager getInstance();  }
@Test public void testBrainkeyDictionaryManager() { assertThat(BrainkeyDictionaryManager.getInstance().getBrainKeyDictionary().length, equalTo(NUMBER_OF_WORDS)); }