chore(testserver): prepare test server (#3294)

This commit is contained in:
Andrey Lushnikov
2018-09-24 12:46:39 -07:00
committed by GitHub
parent 9c89090f73
commit 85aca8e1a5
9 changed files with 252 additions and 16 deletions

View File

@@ -1,7 +1,7 @@
const path = require('path');
const fs = require('fs');
const puppeteer = require('../..');
const SimpleServer = require('../../test/server/SimpleServer');
const {TestServer} = require('../testserver/');
const {TestRunner, Reporter, Matchers} = require('../testrunner/');
const puppeteerWebPath = path.join(__dirname, 'puppeteer-web.js');
@@ -22,7 +22,7 @@ const defaultBrowserOptions = {
beforeAll(async state => {
const assetsPath = path.join(__dirname, '..', '..', 'test', 'assets');
const port = 8998;
state.server = await SimpleServer.create(assetsPath, port);
state.server = await TestServer.create(assetsPath, port);
state.serverConfig = {
PREFIX: `http://localhost:${port}`,
EMPTY_PAGE: `http://localhost:${port}/empty.html`,