]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - server/tests/api/server/no-client.ts
Try to fix travis
[github/Chocobozzz/PeerTube.git] / server / tests / api / server / no-client.ts
CommitLineData
b83b8dd5
RK
1import 'mocha'
2import * as request from 'supertest'
3import {
4 flushTests,
5 killallServers,
6 ServerInfo
94565d52 7} from '../../../../shared/extra-utils'
210feb6c 8import { flushAndRunServer } from '../../../../shared/extra-utils/server/servers'
b83b8dd5
RK
9
10describe('Start and stop server without web client routes', function () {
11 let server: ServerInfo
12
13 before(async function () {
14 this.timeout(30000)
15
210feb6c 16 server = await flushAndRunServer(1, {}, ['--no-client'])
b83b8dd5
RK
17 })
18
19 it('Should fail getting the client', function () {
20 const req = request(server.url)
21 .get('/')
22
23 return req.expect(404)
24 })
25
210feb6c 26 after(function () {
b83b8dd5 27 killallServers([ server ])
b83b8dd5
RK
28 })
29})