TopInstanceCommand extends AbstractCommand { public void run() throws OdpsException, ODPSConsoleException { Odps odps = getCurrentOdps(); if ((delay != null) && InPlaceUpdates.isUnixTerminal()) { autoRefreshQueue(odps); } else { printQueue(getQueue(odps)); } } TopInstanceCommand(String projectName, String commandText, ExecutionContext context); static void printUsage(PrintStream stream); void setNubmer(Integer nubmer); void setDelay(Integer delay); void setOnlyOwner(Boolean onlyOwner); void setStatus(Instance.Status status); void run(); static TopInstanceCommand parse(String commandString, ExecutionContext sessionContext); static final String[] HELP_TAGS; }
@Test public void testRun() throws OdpsException, ODPSConsoleException { ExecutionContext ctx = ExecutionContext.init(); TopInstanceCommand test = TopInstanceCommand.parse(positive[0], ctx); test.run(); }