Skip to content

Commit

Permalink
fix(ppfox): check directory existance if necessary when running tests (
Browse files Browse the repository at this point in the history
  • Loading branch information
aslushnikov committed Feb 1, 2019
1 parent a2f1e27 commit d89ec00
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions experimental/puppeteer-firefox/misc/install-preferences.js
Expand Up @@ -16,8 +16,10 @@ async function installFirefoxPreferences(executablePath) {
prefPath = path.join(firefoxFolder, '..', 'Resources', 'defaults', 'pref');
configPath = path.join(firefoxFolder, '..', 'Resources');
} else if (os.platform() === 'linux') {
await mkdirAsync(path.join(firefoxFolder, 'browser', 'defaults'));
await mkdirAsync(path.join(firefoxFolder, 'browser', 'defaults', 'preferences'));
if (!fs.existsSync(path.join(firefoxFolder, 'browser', 'defaults')))
await mkdirAsync(path.join(firefoxFolder, 'browser', 'defaults'));
if (!fs.existsSync(path.join(firefoxFolder, 'browser', 'defaults', 'preferences')))
await mkdirAsync(path.join(firefoxFolder, 'browser', 'defaults', 'preferences'));
prefPath = path.join(firefoxFolder, 'browser', 'defaults', 'preferences');
configPath = firefoxFolder;
} else if (os.platform() === 'win32') {
Expand Down

0 comments on commit d89ec00

Please sign in to comment.