def test_get_file_wrong_field(self):
        view = setup_view(views.ObjectDownloadView(file_field='other_field'),
                          'fake request')
        view.object = mock.Mock(spec=['file'])
        with self.assertRaises(AttributeError):
            view.get_file()
ObjectDownloadView.get_file() raises AttributeError if field does
dataset/ETHPy150Open benoitbryon/django-downloadview/tests/views.py/ObjectDownloadViewTestCase.test_get_file_wrong_field