def _inner(hostname, rack, rank, appliance, interface):
    cmd = f'stack add host {hostname} rack={rack} rank={rank} appliance={appliance}'
    result = subprocess.run(cmd.split())
    if (result.returncode != 0):
        pytest.fail('unable to add a dummy host')
    cmd = f'stack add host interface {hostname} interface={interface}'
    result = subprocess.run(cmd.split())
    if (result.returncode != 0):
        pytest.fail('unable to add a dummy interface')
def _inner(hostname, rack, rank, appliance, interface):
    cmd = f'stack add host {hostname} rack={rack} rank={rank} appliance={appliance}'
    result = subprocess.run(cmd.split())
    if (result.returncode != 0):
        pytest.fail('unable to add a dummy host')
    cmd = f'stack add host interface {hostname} interface={interface}'
    result = subprocess.run(cmd.split())
    if (result.returncode != 0):
        pytest.fail('unable to add a dummy interface')