X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=server%2Ftests%2Fapi%2Fserver%2Fconfig.ts;h=1782a86236a9ea3584a4ee48b9dd344f5846f41a;hb=5bcfd02974389e1a131496d22f4321a79bed0fbb;hp=7d21b6ce9cfdb2a116fdbb58766cd1d88c81c946;hpb=6e930af9f8f3a3b95c4693600ff8558bca3173ad;p=oweals%2Fpeertube.git diff --git a/server/tests/api/server/config.ts b/server/tests/api/server/config.ts index 7d21b6ce9..1782a8623 100644 --- a/server/tests/api/server/config.ts +++ b/server/tests/api/server/config.ts @@ -4,16 +4,19 @@ import 'mocha' import * as chai from 'chai' import { About } from '../../../../shared/models/server/about.model' import { CustomConfig } from '../../../../shared/models/server/custom-config.model' -import { deleteCustomConfig, getAbout, killallServers, makeHTMLRequest, reRunServer } from '../../utils' -const expect = chai.expect - +import { deleteCustomConfig, getAbout, killallServers, reRunServer } from '../../utils' import { - getConfig, flushTests, + getConfig, + getCustomConfig, + registerUser, runServer, - registerUser, getCustomConfig, setAccessTokensToServers, updateCustomConfig + setAccessTokensToServers, + updateCustomConfig } from '../../utils/index' +const expect = chai.expect + function checkInitialConfig (data: CustomConfig) { expect(data.instance.name).to.equal('PeerTube') expect(data.instance.shortDescription).to.equal( @@ -69,12 +72,6 @@ function checkUpdatedConfig (data: CustomConfig) { expect(data.transcoding.resolutions['1080p']).to.be.false } -function checkIndexTags (html: string, title: string, description: string, css: string) { - expect(html).to.contain('