GeneralDelegate extends Delegate { public String getKeylogfile() { return keylogfile; } GeneralDelegate(); boolean isHelp(); void setHelp(boolean help); boolean isDebug(); void setDebug(boolean debug); boolean isQuiet(); void setQuiet(boolean quiet); String getKeylogfile(); void setKeylogfile(String keylogfile); @Override void applyDelegate(Config config);  }
@Test public void testIsKeylogfile() { args = new String[2]; args[0] = "-keylogfile"; args[1] = "abc"; assertNull(delegate.getKeylogfile()); jcommander.parse(args); assertEquals("abc", delegate.getKeylogfile()); }