Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / chrome / test / data / extensions / api_test / mdns / api / force_discovery.js
blob79bbddfca256adefec47c979c3f3cc7fe65d2951
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 onload = function() {
6 chrome.test.runTests([
7 function registerListener() {
8 var numEvents = 0;
9 chrome.mdns.onServiceList.addListener(function(services) {
10 chrome.mdns.forceDiscovery(function() {
11 chrome.test.assertTrue(!chrome.runtime.lastError);
12 chrome.test.succeed();
13 });
14 }, {'serviceType': '_googlecast._tcp.local'});
15 chrome.test.notifyPass();
17 ]);