test: remove usage of the remote module from tests (#23577)

Co-authored-by: Milan Burda <milan.burda@gmail.com>
This commit is contained in:
trop[bot]
2020-05-18 10:29:52 +09:00
committed by GitHub
parent 9988beabb5
commit fcf50849f3

View File

@@ -3,7 +3,7 @@
<script type="text/javascript" charset="utf-8">
window.onbeforeunload = function() {
setTimeout(function() {
require('electron').remote.getCurrentWindow().emit('onbeforeunload');
require('electron').ipcRenderer.sendSync('onbeforeunload');
}, 0);
}
window.onload = () => window.close();