aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-02-28 16:03:39 +0100
committerChocobozzz <me@florianbigard.com>2020-02-28 16:21:34 +0100
commitbdd428a6d9138d751f8cde82867022a93f1a76cc (patch)
treec2b671c3d6a34daddd20e30656f573cf59905f13 /server/tests
parent9d94e5d7b96332d628ed835c67c2986289ead9b2 (diff)
downloadPeerTube-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.ts2
-rw-r--r--server/tests/api/server/tracker.ts6
-rw-r--r--server/tests/cli/prune-storage.ts2
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/
63import { VideoPrivacy } from '../../../../shared/models/videos' 63import { VideoPrivacy } from '../../../../shared/models/videos'
64import { getBadVideoUrl, getYoutubeVideoUrl, importVideo } from '../../../../shared/extra-utils/videos/video-imports' 64import { getBadVideoUrl, getYoutubeVideoUrl, importVideo } from '../../../../shared/extra-utils/videos/video-imports'
65import { addVideoCommentReply, addVideoCommentThread } from '../../../../shared/extra-utils/videos/video-comments' 65import { addVideoCommentReply, addVideoCommentThread } from '../../../../shared/extra-utils/videos/video-comments'
66import * as uuidv4 from 'uuid/v4' 66import { v4 as uuidv4 } from 'uuid'
67import { addAccountToAccountBlocklist, removeAccountFromAccountBlocklist } from '../../../../shared/extra-utils/users/blocklist' 67import { addAccountToAccountBlocklist, removeAccountFromAccountBlocklist } from '../../../../shared/extra-utils/users/blocklist'
68import { CustomConfig } from '../../../../shared/models/server' 68import { CustomConfig } from '../../../../shared/models/server'
69import { VideoCommentThreadTree } from '../../../../shared/models/videos/video-comment.model' 69import { 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'
23import { Account, VideoPlaylistPrivacy } from '../../../shared/models' 23import { Account, VideoPlaylistPrivacy } from '../../../shared/models'
24import { createFile, readdir } from 'fs-extra' 24import { createFile, readdir } from 'fs-extra'
25import * as uuidv4 from 'uuid/v4' 25import { v4 as uuidv4 } from 'uuid'
26import { join } from 'path' 26import { join } from 'path'
27 27
28const expect = chai.expect 28const expect = chai.expect