diff options
author | Chocobozzz <me@florianbigard.com> | 2021-09-09 09:47:59 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-09-09 09:47:59 +0200 |
commit | afe501a6cd49fe046ac987ac6f8c09f3f730c40a (patch) | |
tree | f74841a757cc61fd030d02a49a1b1ec640e261a8 /server/tests | |
parent | 29b84d749eb650c75b143b523bfe088a43617d82 (diff) | |
download | PeerTube-afe501a6cd49fe046ac987ac6f8c09f3f730c40a.tar.gz PeerTube-afe501a6cd49fe046ac987ac6f8c09f3f730c40a.tar.zst PeerTube-afe501a6cd49fe046ac987ac6f8c09f3f730c40a.zip |
Fix client tests
Diffstat (limited to 'server/tests')
-rw-r--r-- | server/tests/client.ts | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/server/tests/client.ts b/server/tests/client.ts index 4f0d052c8..a91bec906 100644 --- a/server/tests/client.ts +++ b/server/tests/client.ts | |||
@@ -24,7 +24,10 @@ function checkIndexTags (html: string, title: string, description: string, css: | |||
24 | expect(html).to.contain('<style class="custom-css-style">' + css + '</style>') | 24 | expect(html).to.contain('<style class="custom-css-style">' + css + '</style>') |
25 | 25 | ||
26 | const htmlConfig: HTMLServerConfig = omit(config, 'signup') | 26 | const htmlConfig: HTMLServerConfig = omit(config, 'signup') |
27 | expect(html).to.contain(`<script type="application/javascript">window.PeerTubeServerConfig = '${JSON.stringify(htmlConfig)}'</script>`) | 27 | const configObjectString = JSON.stringify(htmlConfig) |
28 | const configEscapedString = JSON.stringify(configObjectString) | ||
29 | |||
30 | expect(html).to.contain(`<script type="application/javascript">window.PeerTubeServerConfig = ${configEscapedString}</script>`) | ||
28 | } | 31 | } |
29 | 32 | ||
30 | describe('Test a client controllers', function () { | 33 | describe('Test a client controllers', function () { |