Skip to content

Commit

Permalink
test: remove hacks on app.quit
Browse files Browse the repository at this point in the history
  • Loading branch information
zcbenz committed Dec 12, 2019
1 parent 01e87e9 commit 8609c38
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 15 deletions.
2 changes: 1 addition & 1 deletion spec-main/fixtures/api/leak-exit-webcontentsview.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ app.on('ready', function () {
const web = webContents.create({})
new WebContentsView(web) // eslint-disable-line

process.nextTick(() => app.quit())
app.quit()
})
4 changes: 1 addition & 3 deletions spec/fixtures/api/command-line/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,5 @@ app.on('ready', () => {
process.stdout.write(JSON.stringify(payload))
process.stdout.end()

setImmediate(() => {
app.quit()
})
app.quit()
})
4 changes: 1 addition & 3 deletions spec/fixtures/api/cookie-app/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@ app.on('ready', async function () {
} finally {
process.stdout.end()

setImmediate(() => {
app.quit()
})
app.quit()
}
})
4 changes: 1 addition & 3 deletions spec/fixtures/api/ipc-main-listeners/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,5 @@ app.on('ready', () => {
process.stdout.write(JSON.stringify(ipcMain.eventNames()))
process.stdout.end()

setImmediate(() => {
app.quit()
})
app.quit()
})
2 changes: 1 addition & 1 deletion spec/fixtures/api/leak-exit-browserview.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ const { BrowserView, app } = require('electron')
app.on('ready', function () {
new BrowserView({}) // eslint-disable-line

process.nextTick(() => app.quit())
app.quit()
})
2 changes: 1 addition & 1 deletion spec/fixtures/api/leak-exit-webcontents.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ const { app, webContents } = require('electron')
app.on('ready', function () {
webContents.create({})

process.nextTick(() => app.quit())
app.quit()
})
4 changes: 1 addition & 3 deletions spec/fixtures/api/locale-check/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,5 @@ app.on('ready', () => {
process.stdout.write(app.getLocale())
process.stdout.end()

setImmediate(() => {
app.quit()
})
app.quit()
})

0 comments on commit 8609c38

Please sign in to comment.