Wrong tests configuration in this case:
// jest-playwright.config.js
module.exports = {
browsers: ['chromium', 'webkit', 'firefox'],
devices: [
'iPhone 11',
{
name: 'Desktop',
...
}
],
useDefaultBrowserType: true,
}
Expected that it will be run 4 times (webkit iPhone 11, webkit Desktop, firefox Desktop, chromium Desktop), but it will run only 2 times (webkit iPhone 11, chromium Desktop).
I suppose that we should run tests for all browsers if custom device don't have useDefaultBrowserType
As weird workaround it will be ok with this config:
// jest-playwright.config.js
module.exports = {
browsers: ['chromium', 'webkit', 'firefox'],
devices: [
'iPhone 11',
{
name: 'Desktop',
defaultBrowserType: 'webkit'
...
},
{
name: 'Desktop',
defaultBrowserType: 'chromium'
...
},
{
name: 'Desktop',
defaultBrowserType: 'firefox'
...
},
],
useDefaultBrowserType: true,
}