示例#1
0
def test_bad_invalid_person_throws_error(text_mock):
    text_mock.return_value = invalid_user_response
    lv = LocationVerification(LocationName='room', PersonName='calvin')

    with pytest.raises(ValueError) as exc:
        assert lv.verify_valid_user()

    assert 'Person does not exist' in str(exc.value)
示例#2
0
def test_can_send_verify_location_request(text_mock):
    text_mock.return_value = verify_location_response
    lv = LocationVerification(LocationName='room', PersonName='calvin')
    assert lv.verify_valid_user()