def test_opengrok_binary(command): """ Test that installed command is able to run :param command: the command name :return: """ print('DEBUG: {}'.format(command)) cmd = Command([command, '--help']) cmd.execute() print('DEBUG: out = {}'.format(cmd.getoutputstr())) assert cmd.getretcode() == 0 assert cmd.getstate() == Command.FINISHED assert len(cmd.getoutputstr()) > 1
def test_opengrok_binary(command): """ Test that installed command is able to run :param command: the command name :return: """ cmd = Command([command, '--help']) cmd.execute() assert cmd.getretcode() == 0 assert cmd.getstate() == Command.FINISHED assert len(cmd.getoutputstr()) > 1
def test_opengrok_version(command): """ Test that installed command has the version option :param command: the command name :return: """ cmd = Command([command, '--version']) cmd.execute() assert cmd.getretcode() == 0 assert cmd.getstate() == Command.FINISHED assert version in cmd.getoutputstr()