Skip to content

Commit ede48c4

Browse files
author
Brian Vaughn
committed
Explicitly install nested DevTools extension dependencies for tests
1 parent b9b9131 commit ede48c4

File tree

1 file changed

+20
-1
lines changed

1 file changed

+20
-1
lines changed

scripts/jest/jest-cli.js

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
'use strict';
22

3-
const {spawn} = require('child_process');
3+
const {spawn, spawnSync} = require('child_process');
44
const chalk = require('chalk');
55
const yargs = require('yargs');
66
const fs = require('fs');
@@ -310,6 +310,25 @@ function main() {
310310
const args = getCommandArgs();
311311
const envars = getEnvars();
312312

313+
if (argv.project === 'devtools') {
314+
console.log(
315+
chalk.blue(
316+
`\nInstalling Yarn dependencies for nested react-devtools-extensions package ...`
317+
)
318+
);
319+
320+
spawnSync('yarn install', {
321+
stdio: 'inherit',
322+
cwd: path.join(
323+
__dirname,
324+
'..',
325+
'..',
326+
'packages',
327+
'react-devtools-extensions'
328+
),
329+
});
330+
}
331+
313332
// Print the full command we're actually running.
314333
console.log(
315334
chalk.dim(

0 commit comments

Comments
 (0)