@Test
public void testPrintUsage() {

  tool.printUsage();
  String usageMsg = outContent.toString();
  assertTrue(usageMsg.contains("usage: <endpoints-tool> <command> <options> [args]"));
  // Make sure only get-client-lib, get-discovery-doc and help command are displayed in usage.
  assertTrue(usageMsg.contains("get-client-lib"));
  assertTrue(usageMsg.contains("get-discovery-doc"));
  assertTrue(usageMsg.contains("help"));
  assertFalse(usageMsg.contains("gen-api-config"));
  assertFalse(usageMsg.contains("gen-discovery-doc"));
  assertFalse(usageMsg.contains("gen-client-lib"));
}