def METHOD_NAME(data, expected_class):
    """Test load_entity function."""
    # protect data for future comparison
    expected_data = deepcopy(data)
    entity = load_entity(data)
    assert isinstance(entity, expected_class)
    assert expected_data == entity.dict()