def itest_get_load_balancing():
    response = BigIPMock.create_mock_response(
        200, BigIPMock.read_json_file(JSON_FILE))

    big_ip = BigIPMock(response)
    test_pool = Pool(big_ip)

    mode = test_pool.get_lb_method("my-Pool")
    assert mode == "ROUND_ROBIN"
def itest_get_description():
    response = BigIPMock.create_mock_response(
        200, BigIPMock.read_json_file(JSON_FILE))

    big_ip = BigIPMock(response)
    test_pool = Pool(big_ip)

    description = test_pool.get_description("my-Pool")
    assert description == "sdfds"
Example #3
0
def itest_get_load_balancing():
    response = BigIPMock.create_mock_response(
        200, BigIPMock.read_json_file(JSON_FILE))

    big_ip = BigIPMock(response)
    test_pool = Pool(big_ip)

    mode = test_pool.get_lb_method("my-Pool")
    assert mode == "ROUND_ROBIN"
Example #4
0
def itest_get_description():
    response = BigIPMock.create_mock_response(
        200, BigIPMock.read_json_file(JSON_FILE))

    big_ip = BigIPMock(response)
    test_pool = Pool(big_ip)

    description = test_pool.get_description("my-Pool")
    assert description == "sdfds"
def itest_get_description_error():
    response = BigIPMock.create_mock_response(
        500, BigIPMock.read_json_file(JSON_FILE))

    big_ip = BigIPMock(response)
    test_pool = Pool(big_ip)

    # should raise a PoolQueryException
    with pytest.raises(exceptions.PoolQueryException):
        test_pool.get_description("my-Pool")
Example #6
0
def itest_get_description_error():
    response = BigIPMock.create_mock_response(
        500, BigIPMock.read_json_file(JSON_FILE))

    big_ip = BigIPMock(response)
    test_pool = Pool(big_ip)

    # should raise a PoolQueryException
    with pytest.raises(exceptions.PoolQueryException):
        test_pool.get_description("my-Pool")