Fix client tests
This commit is contained in:
parent
29b84d749e
commit
afe501a6cd
1 changed files with 4 additions and 1 deletions
|
@ -24,7 +24,10 @@ function checkIndexTags (html: string, title: string, description: string, css:
|
||||||
expect(html).to.contain('<style class="custom-css-style">' + css + '</style>')
|
expect(html).to.contain('<style class="custom-css-style">' + css + '</style>')
|
||||||
|
|
||||||
const htmlConfig: HTMLServerConfig = omit(config, 'signup')
|
const htmlConfig: HTMLServerConfig = omit(config, 'signup')
|
||||||
expect(html).to.contain(`<script type="application/javascript">window.PeerTubeServerConfig = '${JSON.stringify(htmlConfig)}'</script>`)
|
const configObjectString = JSON.stringify(htmlConfig)
|
||||||
|
const configEscapedString = JSON.stringify(configObjectString)
|
||||||
|
|
||||||
|
expect(html).to.contain(`<script type="application/javascript">window.PeerTubeServerConfig = ${configEscapedString}</script>`)
|
||||||
}
|
}
|
||||||
|
|
||||||
describe('Test a client controllers', function () {
|
describe('Test a client controllers', function () {
|
||||||
|
|
Loading…
Reference in a new issue