wait,
waitUntilLog,
checkVideoFilesWereRemoved, removeVideo
-} from '../../utils'
-import { waitJobs } from '../../utils/server/jobs'
+} from '../../../../shared/utils'
+import { waitJobs } from '../../../../shared/utils/server/jobs'
import * as magnetUtil from 'magnet-uri'
-import { updateRedundancy } from '../../utils/server/redundancy'
+import { updateRedundancy } from '../../../../shared/utils/server/redundancy'
import { ActorFollow } from '../../../../shared/models/actors'
import { readdir } from 'fs-extra'
import { join } from 'path'
import { VideoRedundancyStrategy } from '../../../../shared/models/redundancy'
-import { getStats } from '../../utils/server/stats'
+import { getStats } from '../../../../shared/utils/server/stats'
import { ServerStats } from '../../../../shared/models/server/server-stats.model'
const expect = chai.expect
immutableAssign({
min_lifetime: '1 hour',
strategy: strategy,
- size: '200KB'
+ size: '100KB'
}, additionalParams)
]
}
const stat = data.videosRedundancy[0]
expect(stat.strategy).to.equal(strategy)
- expect(stat.totalSize).to.equal(204800)
- expect(stat.totalUsed).to.be.at.least(1).and.below(204800)
+ expect(stat.totalSize).to.equal(102400)
+ expect(stat.totalUsed).to.be.at.least(1).and.below(102401)
expect(stat.totalVideoFiles).to.equal(4)
expect(stat.totalVideos).to.equal(1)
}
const stat = data.videosRedundancy[0]
expect(stat.strategy).to.equal(strategy)
- expect(stat.totalSize).to.equal(204800)
+ expect(stat.totalSize).to.equal(102400)
expect(stat.totalUsed).to.equal(0)
expect(stat.totalVideoFiles).to.equal(0)
expect(stat.totalVideos).to.equal(0)
return enableRedundancyOnServer1()
})
- it('Should have 2 webseeds on the first video', async function () {
+ it('Should have 2 webseed on the first video', async function () {
this.timeout(40000)
await waitJobs(servers)
return enableRedundancyOnServer1()
})
- it('Should have 2 webseeds on the first video', async function () {
+ it('Should have 2 webseed on the first video', async function () {
this.timeout(40000)
await waitJobs(servers)
await waitJobs(servers)
})
- it('Should have 2 webseeds on the first video', async function () {
+ it('Should have 2 webseed on the first video', async function () {
this.timeout(40000)
await waitJobs(servers)
await enableRedundancyOnServer1()
})
- it('Should still have 2 webseedss after 10 seconds', async function () {
+ it('Should still have 2 webseeds after 10 seconds', async function () {
this.timeout(40000)
await wait(10000)
video2Server2UUID = res.body.video.uuid
})
- it('Should cache video 2 webseeds on the first video', async function () {
+ it('Should cache video 2 webseed on the first video', async function () {
this.timeout(120000)
await waitJobs(servers)