diff options
author | Matt A. Tobin <email@mattatobin.com> | 2018-02-03 06:00:38 -0500 |
---|---|---|
committer | Matt A. Tobin <email@mattatobin.com> | 2018-02-03 06:00:38 -0500 |
commit | 8148615da179fdd60f19018e13b4e94b95609cc6 (patch) | |
tree | 771fccdd99fa3adf35fdd2c81d8197b415a89b91 /browser/components/originattributes/test/browser/worker_deblobify.js | |
parent | 494802c1be7888025b95260d23db187467d2b9dd (diff) | |
download | UXP-8148615da179fdd60f19018e13b4e94b95609cc6.tar UXP-8148615da179fdd60f19018e13b4e94b95609cc6.tar.gz UXP-8148615da179fdd60f19018e13b4e94b95609cc6.tar.lz UXP-8148615da179fdd60f19018e13b4e94b95609cc6.tar.xz UXP-8148615da179fdd60f19018e13b4e94b95609cc6.zip |
Remove browser tests - Part 1: The Tests (except for experiments)
Diffstat (limited to 'browser/components/originattributes/test/browser/worker_deblobify.js')
-rw-r--r-- | browser/components/originattributes/test/browser/worker_deblobify.js | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/browser/components/originattributes/test/browser/worker_deblobify.js b/browser/components/originattributes/test/browser/worker_deblobify.js deleted file mode 100644 index 1d6511a20..000000000 --- a/browser/components/originattributes/test/browser/worker_deblobify.js +++ /dev/null @@ -1,31 +0,0 @@ -// Wait for a blob URL to be posted to this worker. -// Obtain the blob, and read the string contained in it. -// Post back the string. - -var postStringInBlob = function (blobObject) { - var fileReader = new FileReaderSync(); - var result = fileReader.readAsText(blobObject); - postMessage(result); -}; - -self.addEventListener("message", function (e) { - if ("error" in e.data) { - postMessage(e.data); - return; - } - var blobURL = e.data.blobURL, - xhr = new XMLHttpRequest(); - try { - xhr.open("GET", blobURL, true); - xhr.onload = function () { - postStringInBlob(xhr.response); - }; - xhr.onerror = function () { - postMessage({ error: "xhr error" }); - }; - xhr.responseType = "blob"; - xhr.send(); - } catch (e) { - postMessage({ error: e.message }); - } -}, false); |