From c8c4e4fa3d31ca692e81fd26dcc4cae5bc91c81a Mon Sep 17 00:00:00 2001 From: Max Brunsfeld Date: Thu, 26 Jul 2018 10:23:51 -0700 Subject: [PATCH] Delete redundant test for on atom.onUpdateAvailable This test emitted an event in the main process, which caused exceptions in all *other* Atom windows :scream_cat:. --- spec/atom-environment-spec.js | 23 ----------------------- 1 file changed, 23 deletions(-) diff --git a/spec/atom-environment-spec.js b/spec/atom-environment-spec.js index 5574e9663..37f7de72c 100644 --- a/spec/atom-environment-spec.js +++ b/spec/atom-environment-spec.js @@ -746,29 +746,6 @@ describe('AtomEnvironment', () => { }) }) - describe('::updateAvailable(info) (called via IPC from browser process)', () => { - let subscription - - afterEach(() => { - if (subscription) subscription.dispose() - }) - - it('invokes onUpdateAvailable listeners', async () => { - if (process.platform !== 'darwin') return // Test tied to electron autoUpdater, we use something else on Linux and Win32 - - const updateAvailablePromise = new Promise(resolve => { - subscription = atom.onUpdateAvailable(resolve) - }) - - atom.listenForUpdates() - const {autoUpdater} = require('electron').remote - autoUpdater.emit('update-downloaded', null, 'notes', 'version') - - const {releaseVersion} = await updateAvailablePromise - expect(releaseVersion).toBe('version') - }) - }) - describe('::getReleaseChannel()', () => { let version