author | Gavin Sharp <gavin@gavinsharp.com> |
Mon, 12 Nov 2012 22:24:59 -0800 | |
changeset 113064 | a06a34a849551211c9352c79d09678f31faa1e06 |
parent 113063 | a2cdd1e642672e54533648fabb01c2f4a20c4122 |
child 113065 | 2b31de6440468683e51c55314fd81ac34d1d6cb9 |
push id | 17922 |
push user | gsharp@mozilla.com |
push date | Tue, 13 Nov 2012 06:27:03 +0000 |
treeherder | mozilla-inbound@a06a34a84955 [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | markh |
bugs | 811102, 804910 |
milestone | 19.0a1 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
toolkit/components/social/test/browser/browser_frameworker.js | file | annotate | diff | comparison | revisions |
--- a/toolkit/components/social/test/browser/browser_frameworker.js +++ b/toolkit/components/social/test/browser/browser_frameworker.js @@ -461,71 +461,75 @@ let tests = { } ioService.offline = false; } ioService.offline = true; } }, testMissingWorker: function(cbnext) { + let worker = getFrameWorkerHandle(url, undefined, "testMissingWorker"); Services.obs.addObserver(function handleError() { Services.obs.removeObserver(handleError, "social:frameworker-error"); ok(true, "social:frameworker-error was handled"); + worker.terminate(); cbnext(); }, 'social:frameworker-error', false); // don't ever create this file! We want a 404. let url = "https://example.com/browser/toolkit/components/social/test/browser/worker_is_missing.js"; - let worker = getFrameWorkerHandle(url, undefined, "testMissingWorker"); worker.port.onmessage = function(e) { ok(false, "social:frameworker-error was handled"); cbnext(); } }, testNoConnectWorker: function(cbnext) { + let worker = getFrameWorkerHandle(makeWorkerUrl(function () {}), + undefined, "testNoConnectWorker"); Services.obs.addObserver(function handleError() { Services.obs.removeObserver(handleError, "social:frameworker-error"); ok(true, "social:frameworker-error was handled"); + worker.terminate(); cbnext(); }, 'social:frameworker-error', false); - let worker = getFrameWorkerHandle(makeWorkerUrl(function () {}), - undefined, "testNoConnectWorker"); worker.port.onmessage = function(e) { ok(false, "social:frameworker-error was handled"); cbnext(); } }, testEmptyWorker: function(cbnext) { + let worker = getFrameWorkerHandle("data:application/javascript;charset=utf-8,", + undefined, "testEmptyWorker"); Services.obs.addObserver(function handleError() { Services.obs.removeObserver(handleError, "social:frameworker-error"); ok(true, "social:frameworker-error was handled"); + worker.terminate(); cbnext(); }, 'social:frameworker-error', false); - let worker = getFrameWorkerHandle("data:application/javascript;charset=utf-8,", - undefined, "testEmptyWorker"); worker.port.onmessage = function(e) { ok(false, "social:frameworker-error was handled"); cbnext(); } }, testWorkerConnectError: function(cbnext) { + let worker = getFrameWorkerHandle(makeWorkerUrl(run), + undefined, "testWorkerConnectError"); Services.obs.addObserver(function handleError() { Services.obs.removeObserver(handleError, "social:frameworker-error"); ok(true, "social:frameworker-error was handled"); + worker.terminate(); cbnext(); }, 'social:frameworker-error', false); let run = function () { onconnect = function(e) { throw new Error("worker failure"); } } - let worker = getFrameWorkerHandle(makeWorkerUrl(run), - undefined, "testWorkerConnectError"); worker.port.onmessage = function(e) { ok(false, "social:frameworker-error was handled"); cbnext(); } }, testReloadAndNewPort: function(cbnext) { let run = function () {