Time out after 5 minutes
This commit is contained in:
parent
c85d667e66
commit
39fdc26921
1 changed files with 7 additions and 1 deletions
8
spec/fixtures/no-proprietary-codecs.js
vendored
8
spec/fixtures/no-proprietary-codecs.js
vendored
|
@ -9,6 +9,7 @@ const path = require('path')
|
|||
const url = require('url')
|
||||
|
||||
const MEDIA_ERR_SRC_NOT_SUPPORTED = 4
|
||||
const FIVE_MINUTES = 5 * 60 * 1000
|
||||
|
||||
let window
|
||||
|
||||
|
@ -23,7 +24,7 @@ app.once('ready', () => {
|
|||
pathname: path.resolve(__dirname, 'asar', 'video.asar', 'index.html')
|
||||
}))
|
||||
|
||||
ipcMain.on('asar-video', function (event, message, error) {
|
||||
ipcMain.on('asar-video', (event, message, error) => {
|
||||
if (message === 'ended') {
|
||||
console.log('Video played, proprietary codecs are included')
|
||||
app.exit(1)
|
||||
|
@ -38,4 +39,9 @@ app.once('ready', () => {
|
|||
console.log(`Unexpected response from page: ${message} ${error}`)
|
||||
app.exit(1)
|
||||
})
|
||||
|
||||
setTimeout(() => {
|
||||
console.log('No IPC message after 5 minutes')
|
||||
app.exit(1)
|
||||
}, FIVE_MINUTES)
|
||||
})
|
||||
|
|
Loading…
Add table
Reference in a new issue