Пример #1
0
def test_check_node_not_exist_wrong_ip_with_failed(environment, capsys):
    assert not fox.check_node_exist(environment.group, '123.123.123.123', True)

    out, err = capsys.readouterr()
    assert build_message(environment.group, '123.123.123.123') in out
Пример #2
0
def test_check_node_not_exist_wrong_group_with_failed(environment, capsys):
    assert not fox.check_node_exist('Strange_Group_Env',
                                    environment.replication, True)

    out, err = capsys.readouterr()
    assert build_message('Strange_Group_Env', environment.replication) in out
Пример #3
0
def test_check_node_not_exist_with_failed(environment, capsys):
    assert not fox.check_node_exist('Strange_Group_Env', '987.654.321.666',
                                    True)

    out, err = capsys.readouterr()
    assert build_message('Strange_Group_Env', '987.654.321.666') in out
Пример #4
0
def test_check_failed_node_not_exist(environment, capsys):
    test_utils.failed_node(environment.replication, capsys)
    assert not fox.check_node_exist(environment.group, environment.replication,
                                    False)
    out, err = capsys.readouterr()
    assert build_message(environment.group, environment.replication) in out
Пример #5
0
def test_check_failed_node_exist(environment, capsys):
    test_utils.failed_node(environment.replication, capsys)
    assert fox.check_node_exist(environment.group, environment.replication,
                                True)
Пример #6
0
def test_check_node_exist(environment):
    assert fox.check_node_exist(environment.group, environment.replication,
                                False)