From 8b3aa4dbb4e9827f5abd72ed2cf52b7f6a89b27a Mon Sep 17 00:00:00 2001 From: Kevin Sawicki Date: Mon, 8 Aug 2016 09:35:30 -0700 Subject: [PATCH] Add spec for sending document.location over IPC --- spec/api-ipc-spec.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/spec/api-ipc-spec.js b/spec/api-ipc-spec.js index 8a57fb0..8d08baf 100644 --- a/spec/api-ipc-spec.js +++ b/spec/api-ipc-spec.js @@ -294,6 +294,15 @@ describe('ipc module', function () { }) ipcRenderer.send('message', currentDate) }) + + it('can send objects with DOM class prototypes', function (done) { + ipcRenderer.once('message', function (event, value) { + assert.equal(value.protocol, 'file:') + assert.equal(value.hostname, '') + done() + }) + ipcRenderer.send('message', document.location) + }) }) describe('ipc.sendSync', function () { -- 2.7.4