fix(service-worker): check platformBrowser before accessing navigator.serviceWorker (#21231)

PR Close #21231
This commit is contained in:
Heo Sangmin
2018-05-10 00:11:43 +09:00
committed by Matias Niemelä
parent afff84c03f
commit 0ee5b7efa5
4 changed files with 99 additions and 19 deletions

View File

@ -80,7 +80,7 @@ const serverUpdate =
async_beforeEach(async() => {
// Fire up the client.
mock = new MockServiceWorkerContainer();
comm = new NgswCommChannel(mock as any, 'browser');
comm = new NgswCommChannel(mock as any);
scope = new SwTestHarnessBuilder().withServerState(server).build();
driver = new Driver(scope, scope, new CacheDatabase(scope, scope));