+
+ it('Should fail to import with HTTP/Torrent/magnet', async function () {
+ this.timeout(30000)
+
+ const baseAttributes = {
+ channelId: 1,
+ privacy: VideoPrivacy.PUBLIC
+ }
+ await importVideo(server.url, server.accessToken, immutableAssign(baseAttributes, { targetUrl: getYoutubeVideoUrl() }))
+ await importVideo(server.url, server.accessToken, immutableAssign(baseAttributes, { magnetUri: getMagnetURI() }))
+ await importVideo(server.url, server.accessToken, immutableAssign(baseAttributes, { torrentfile: '60fps_small-240p.torrent' }))
+
+ await waitJobs([ server ])
+
+ const res = await getMyVideoImports(server.url, server.accessToken)
+
+ expect(res.body.total).to.equal(3)
+ const videoImports: VideoImport[] = res.body.data
+ expect(videoImports).to.have.lengthOf(3)
+
+ for (const videoImport of videoImports) {
+ expect(videoImport.state.id).to.equal(VideoImportState.FAILED)
+ expect(videoImport.error).not.to.be.undefined
+ expect(videoImport.error).to.contain('user video quota is exceeded')
+ }
+ })