def test_make_download(self):
        """The make_download() method creates a Download object."""
        user = self.gw.create_or_update_user(
            'username', visible_name='Visible Name', max_storage_bytes=1)
        udf = self.factory.make_user_volume(
            owner=user._user, path='~/path/name')
        dl_url = 'http://download/url'
        dl_key = uuid.uuid4()
        download = self.gw.make_download(
            user.id, udf.id, 'path', dl_url, dl_key)
        self.assertTrue(isinstance(download, DAODownload))
        self.assertEqual(download.owner_id, user.id)
        self.assertEqual(download.volume_id, udf.id)
        self.assertEqual(download.file_path, 'path')
        self.assertEqual(download.download_url, dl_url)
        self.assertEqual(download.download_key, unicode(repr(dl_key)))