@Test (timeout = 5000)
public void testWithInvalidApplicationId() throws Exception {

  LogsCLI cli = createCli();
  // Specify an invalid applicationId
  int exitCode = cli.run(new String[] {"-applicationId", "123"});
  assertTrue(exitCode == -1);
  assertTrue(sysErrStream.toString().contains(
          "Invalid ApplicationId specified"));
}