Exemple #1
0
def test_no_elections_with_valid_data_and_no_state_entries(get_valid_data):
    entry = Address(street_1=get_valid_data['street_1'],
                    street_2=get_valid_data['street_2'],
                    city=get_valid_data['city'],
                    zip=get_valid_data['zip'])
    response = election.find_elections(entry)
    assert len(response) == 0
def test_greater_than_5_less_than_9_digit_zip_code(
        get_greater_than_5_less_than_9_digit_zip_code_data):
    entry = Address(
        state=get_greater_than_5_less_than_9_digit_zip_code_data['state'],
        zip=get_greater_than_5_less_than_9_digit_zip_code_data['zip'])
    response = election.find_elections(entry)
    # There are no means with which to validate this test given the current state of the project
    assert True
Exemple #3
0
def test_receive_relevant_or_no_elections_with_valid_data_entries(
        get_valid_data):
    entry = Address(street_1=get_valid_data['street_1'],
                    street_2=get_valid_data['street_2'],
                    city=get_valid_data['city'],
                    state=get_valid_data['state'],
                    zip=get_valid_data['zip'])
    response = election.find_elections(entry)
    assert len(response) > 0 or len(response) == 0
def test_street_street2_with_non_alpha_numeric_city_with_alpha_numeric_entries(
        get_nonalphanum_streets_alphanum_city_data):
    entry = Address(street_1=get_nonalphanum_streets_alphanum_city_data['street_1'],
                    street_2=get_nonalphanum_streets_alphanum_city_data['street_2'],
                    city=get_nonalphanum_streets_alphanum_city_data['city'],
                    state=get_nonalphanum_streets_alphanum_city_data['state'])
    response = election.find_elections(entry)
    # There are no means with which to validate this test given the current state of the project
    assert False
Exemple #5
0
def test_receive_relevant_or_no_elections_with_only_state(get_state_data):
    entry = Address(state=get_state_data)
    response = election.find_elections(entry)
    assert len(response) > 0 or len(response) == 0
def test_non_numeric_zip_code(get_non_numeric_zip_code_data):
    entry = Address(state=get_non_numeric_zip_code_data['state'],
                    zip=get_non_numeric_zip_code_data['zip'])
    response = election.find_elections(entry)
    # There are no means with which to validate this test given the current state of the project
    assert False