prepareNotificationsTest
} from '../../../../shared/extra-utils/users/user-notifications'
import { addUserSubscription, removeUserSubscription } from '../../../../shared/extra-utils/users/user-subscriptions'
-import { getBadVideoUrl, getYoutubeVideoUrl, importVideo } from '../../../../shared/extra-utils/videos/video-imports'
+import { getBadVideoUrl, getGoodVideoUrl, importVideo } from '../../../../shared/extra-utils/videos/video-imports'
import { UserNotification, UserNotificationType } from '../../../../shared/models/users'
import { VideoPrivacy } from '../../../../shared/models/videos'
})
it('Should not send notifications if the user does not follow the video publisher', async function () {
- this.timeout(10000)
+ this.timeout(50000)
await uploadRandomVideoOnServers(servers, 1)
})
it('Should send a new video notification on a scheduled publication', async function () {
- this.timeout(20000)
+ this.timeout(50000)
// In 2 seconds
const updateAt = new Date(new Date().getTime() + 2000)
})
it('Should not send a notification before the video is published', async function () {
- this.timeout(20000)
+ this.timeout(50000)
const updateAt = new Date(new Date().getTime() + 1000000)
})
it('Should send a new video notification when a video becomes public', async function () {
- this.timeout(10000)
+ this.timeout(50000)
const data = { privacy: VideoPrivacy.PRIVATE }
const { name, uuid } = await uploadRandomVideoOnServers(servers, 1, data)
})
it('Should send a new video notification when a remote video becomes public', async function () {
- this.timeout(20000)
+ this.timeout(50000)
const data = { privacy: VideoPrivacy.PRIVATE }
const { name, uuid } = await uploadRandomVideoOnServers(servers, 2, data)
})
it('Should not send a new video notification when a video becomes unlisted', async function () {
- this.timeout(20000)
+ this.timeout(50000)
const data = { privacy: VideoPrivacy.PRIVATE }
const { name, uuid } = await uploadRandomVideoOnServers(servers, 1, data)
})
it('Should not send a new video notification when a remote video becomes unlisted', async function () {
- this.timeout(20000)
+ this.timeout(50000)
const data = { privacy: VideoPrivacy.PRIVATE }
const { name, uuid } = await uploadRandomVideoOnServers(servers, 2, data)
name,
channelId,
privacy: VideoPrivacy.PUBLIC,
- targetUrl: getYoutubeVideoUrl()
+ targetUrl: getGoodVideoUrl()
}
const res = await importVideo(servers[0].url, servers[0].accessToken, attributes)
const uuid = res.body.video.uuid
})
it('Should not send a notification if transcoding is not enabled', async function () {
- this.timeout(10000)
+ this.timeout(50000)
const { name, uuid } = await uploadRandomVideoOnServers(servers, 1)
await waitJobs(servers)
name,
channelId,
privacy: VideoPrivacy.PUBLIC,
- targetUrl: getYoutubeVideoUrl(),
+ targetUrl: getGoodVideoUrl(),
waitTranscoding: true
}
const res = await importVideo(servers[1].url, servers[1].accessToken, attributes)
name,
channelId,
privacy: VideoPrivacy.PRIVATE,
- targetUrl: getYoutubeVideoUrl()
+ targetUrl: getGoodVideoUrl()
}
const res = await importVideo(servers[0].url, servers[0].accessToken, attributes)
const uuid = res.body.video.uuid
await waitJobs(servers)
- await checkMyVideoImportIsFinished(baseParams, name, uuid, getYoutubeVideoUrl(), true, 'presence')
+ await checkMyVideoImportIsFinished(baseParams, name, uuid, getGoodVideoUrl(), true, 'presence')
})
})
})
it('Should notify when a local channel is following one of our channel', async function () {
- this.timeout(10000)
+ this.timeout(50000)
await addUserSubscription(servers[0].url, servers[0].accessToken, 'user_1_channel@localhost:' + servers[0].port)
await waitJobs(servers)
})
it('Should notify when a remote channel is following one of our channel', async function () {
- this.timeout(10000)
+ this.timeout(50000)
await addUserSubscription(servers[1].url, servers[1].accessToken, 'user_1_channel@localhost:' + servers[0].port)
await waitJobs(servers)
// PeerTube does not support accout -> account follows
// it('Should notify when a local account is following one of our channel', async function () {
- // this.timeout(10000)
+ // this.timeout(50000)
//
// await addUserSubscription(servers[0].url, servers[0].accessToken, 'user_1@localhost:' + servers[0].port)
//
// })
// it('Should notify when a remote account is following one of our channel', async function () {
- // this.timeout(10000)
+ // this.timeout(50000)
//
// await addUserSubscription(servers[1].url, servers[1].accessToken, 'user_1@localhost:' + servers[0].port)
//