Command { public static Command create(String executable) { checkArgument(!isEmpty(executable), "Command executable can not be blank"); return new Command(executable, new Os()); } Command(String executable, Os os); String getExecutable(); List<String> getArguments(); Command addArgument(String arg); Command addArguments(List<String> args); Command addArguments(String... args); Command addSystemArgument(String key, String value); File getDirectory(); Command setDirectory(File d); Command setEnvironmentVariable(String name, String value); Map<String, String> getEnvironmentVariables(); String toCommandLine(); @Override String toString(); static Command create(String executable);  }
@Test public void fail_if_empty_executable() { thrown.expect(IllegalArgumentException.class); Command.create(""); }
@Test public void fail_if_null_executable() { thrown.expect(IllegalArgumentException.class); Command.create(null); }