Skip to content

Commit

Permalink
tests(smokehouse): fix tmp directory creation (#9855)
Browse files Browse the repository at this point in the history
  • Loading branch information
connorjclark authored and paulirish committed Nov 6, 2019
1 parent d4aa106 commit 0355640
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lighthouse-cli/test/smokehouse/smokehouse.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
/* eslint-disable no-console */

const fs = require('fs');
const mkdirp = require('mkdirp');
const spawnSync = require('child_process').spawnSync;
const yargs = require('yargs');
const log = require('lighthouse-logger');
Expand Down Expand Up @@ -124,7 +125,10 @@ if (!smokeTest) {
throw new Error(`could not find smoke ${smokeId}`);
}

const configPath = `./.tmp/smoke-config-${smokeTest.id}.json`;
const lhRootDir = `${__dirname}/../../..`;
const tmpDir = `${lhRootDir}/.tmp`;
mkdirp.sync(tmpDir);
const configPath = `${tmpDir}/smoke-config-${smokeTest.id}.json`;
fs.writeFileSync(configPath, JSON.stringify(smokeTest.config));

// Loop sequentially over expectations, comparing against Lighthouse run, and
Expand Down

0 comments on commit 0355640

Please sign in to comment.