diff options
author | Chocobozzz <me@florianbigard.com> | 2020-02-28 16:03:39 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2020-02-28 16:21:34 +0100 |
commit | bdd428a6d9138d751f8cde82867022a93f1a76cc (patch) | |
tree | c2b671c3d6a34daddd20e30656f573cf59905f13 /server/tests | |
parent | 9d94e5d7b96332d628ed835c67c2986289ead9b2 (diff) | |
download | PeerTube-bdd428a6d9138d751f8cde82867022a93f1a76cc.tar.gz PeerTube-bdd428a6d9138d751f8cde82867022a93f1a76cc.tar.zst PeerTube-bdd428a6d9138d751f8cde82867022a93f1a76cc.zip |
Update dependencies
Diffstat (limited to 'server/tests')
-rw-r--r-- | server/tests/api/notifications/user-notifications.ts | 2 | ||||
-rw-r--r-- | server/tests/api/server/tracker.ts | 6 | ||||
-rw-r--r-- | server/tests/cli/prune-storage.ts | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/server/tests/api/notifications/user-notifications.ts b/server/tests/api/notifications/user-notifications.ts index 2a632e16f..625e344fa 100644 --- a/server/tests/api/notifications/user-notifications.ts +++ b/server/tests/api/notifications/user-notifications.ts | |||
@@ -63,7 +63,7 @@ import { addUserSubscription, removeUserSubscription } from '../../../../shared/ | |||
63 | import { VideoPrivacy } from '../../../../shared/models/videos' | 63 | import { VideoPrivacy } from '../../../../shared/models/videos' |
64 | import { getBadVideoUrl, getYoutubeVideoUrl, importVideo } from '../../../../shared/extra-utils/videos/video-imports' | 64 | import { getBadVideoUrl, getYoutubeVideoUrl, importVideo } from '../../../../shared/extra-utils/videos/video-imports' |
65 | import { addVideoCommentReply, addVideoCommentThread } from '../../../../shared/extra-utils/videos/video-comments' | 65 | import { addVideoCommentReply, addVideoCommentThread } from '../../../../shared/extra-utils/videos/video-comments' |
66 | import * as uuidv4 from 'uuid/v4' | 66 | import { v4 as uuidv4 } from 'uuid' |
67 | import { addAccountToAccountBlocklist, removeAccountFromAccountBlocklist } from '../../../../shared/extra-utils/users/blocklist' | 67 | import { addAccountToAccountBlocklist, removeAccountFromAccountBlocklist } from '../../../../shared/extra-utils/users/blocklist' |
68 | import { CustomConfig } from '../../../../shared/models/server' | 68 | import { CustomConfig } from '../../../../shared/models/server' |
69 | import { VideoCommentThreadTree } from '../../../../shared/models/videos/video-comment.model' | 69 | import { VideoCommentThreadTree } from '../../../../shared/models/videos/video-comment.model' |
diff --git a/server/tests/api/server/tracker.ts b/server/tests/api/server/tracker.ts index 9d3a274d4..611d5254a 100644 --- a/server/tests/api/server/tracker.ts +++ b/server/tests/api/server/tracker.ts | |||
@@ -49,7 +49,7 @@ describe('Test tracker', function () { | |||
49 | torrent.on('error', done) | 49 | torrent.on('error', done) |
50 | torrent.on('warning', warn => { | 50 | torrent.on('warning', warn => { |
51 | const message = typeof warn === 'string' ? warn : warn.message | 51 | const message = typeof warn === 'string' ? warn : warn.message |
52 | if (message.indexOf('Unknown infoHash ') !== -1) return done() | 52 | if (message.includes('Unknown infoHash ')) return done() |
53 | }) | 53 | }) |
54 | 54 | ||
55 | torrent.on('done', () => done(new Error('No error on infohash'))) | 55 | torrent.on('done', () => done(new Error('No error on infohash'))) |
@@ -64,7 +64,7 @@ describe('Test tracker', function () { | |||
64 | torrent.on('error', done) | 64 | torrent.on('error', done) |
65 | torrent.on('warning', warn => { | 65 | torrent.on('warning', warn => { |
66 | const message = typeof warn === 'string' ? warn : warn.message | 66 | const message = typeof warn === 'string' ? warn : warn.message |
67 | if (message.indexOf('Unknown infoHash ') !== -1) return done(new Error('Error on infohash')) | 67 | if (message.includes('Unknown infoHash ')) return done(new Error('Error on infohash')) |
68 | }) | 68 | }) |
69 | 69 | ||
70 | torrent.on('done', done) | 70 | torrent.on('done', done) |
@@ -83,7 +83,7 @@ describe('Test tracker', function () { | |||
83 | torrent.on('error', done) | 83 | torrent.on('error', done) |
84 | torrent.on('warning', warn => { | 84 | torrent.on('warning', warn => { |
85 | const message = typeof warn === 'string' ? warn : warn.message | 85 | const message = typeof warn === 'string' ? warn : warn.message |
86 | if (message.indexOf('disabled ') !== -1) return done() | 86 | if (message.includes('disabled ')) return done() |
87 | }) | 87 | }) |
88 | 88 | ||
89 | torrent.on('done', () => done(new Error('Tracker is enabled'))) | 89 | torrent.on('done', () => done(new Error('Tracker is enabled'))) |
diff --git a/server/tests/cli/prune-storage.ts b/server/tests/cli/prune-storage.ts index 304c8ca56..6cda80070 100644 --- a/server/tests/cli/prune-storage.ts +++ b/server/tests/cli/prune-storage.ts | |||
@@ -22,7 +22,7 @@ import { | |||
22 | } from '../../../shared/extra-utils' | 22 | } from '../../../shared/extra-utils' |
23 | import { Account, VideoPlaylistPrivacy } from '../../../shared/models' | 23 | import { Account, VideoPlaylistPrivacy } from '../../../shared/models' |
24 | import { createFile, readdir } from 'fs-extra' | 24 | import { createFile, readdir } from 'fs-extra' |
25 | import * as uuidv4 from 'uuid/v4' | 25 | import { v4 as uuidv4 } from 'uuid' |
26 | import { join } from 'path' | 26 | import { join } from 'path' |
27 | 27 | ||
28 | const expect = chai.expect | 28 | const expect = chai.expect |