### Question:
DefaultUserContext implements UserContext { @Override public String getDefaultPrefix(String module) { requireNotBlank(module, "Expected a module name"); return prefs.node(module).get(StringUserPreference.DEFAULT_PREFIX.toString(), "PDFsam_"); } DefaultUserContext(); @Override String getDefaultWorkspacePath(); @Override String getDefaultWorkingPath(); @Override boolean isPlaySounds(); @Override boolean isDonationNotification(); @Override boolean isFetchPremiumModules(); @Override boolean isUseSmartOutput(); @Override boolean isSaveWorkspaceOnExit(); @Override int getNumberOfLogRows(); @Override String getStartupModule(); @Override boolean isCheckForUpdates(); @Override boolean isCheckForNews(); @Override boolean isCompressionEnabled(); @Override boolean isSavePwdInWorkspaceFile(); @Override String getLocale(); @Override String getDefaultPrefix(String module); @Override void setDefaultPrefix(String module, String value); @Override void clear(); @Override void setBooleanPreference(BooleanUserPreference pref, boolean value); @Override void setIntegerPreference(IntUserPreference pref, int value); @Override void setStringPreference(StringUserPreference pref, String value);  }### Answer:
@Test public void getDefaultPrefix() { victim.setDefaultPrefix("module", "banana"); assertEquals("banana", victim.getDefaultPrefix("module")); assertEquals("PDFsam_", victim.getDefaultPrefix("module_2")); victim.setDefaultPrefix("module", ""); assertEquals("", victim.getDefaultPrefix("module")); }
@Test(expected = IllegalArgumentException.class) public void getDefaultPrefixEmptyModule() { victim.getDefaultPrefix(" "); }
@Test(expected = IllegalArgumentException.class) public void getDefaultPrefixNullModule() { victim.getDefaultPrefix(null); }