Skip to content

Commit 239ee72

Browse files
committed
Fix start command in test-snaps (#3155)
`yarn start` in the `test-snaps` folder was broken after #3094. This fixes it.
1 parent 981b921 commit 239ee72

File tree

3 files changed

+20
-2
lines changed

3 files changed

+20
-2
lines changed

.yarn/plugins/local/plugin-workspaces-filter.js

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,16 @@ module.exports = {
144144
validator: isBoolean,
145145
});
146146

147+
interlaced = Option.Boolean(`--interlaced`, false, {
148+
description: `Print the output of commands in real-time instead of buffering it`,
149+
validator: isBoolean,
150+
});
151+
152+
jobs = Option.String(`--jobs`, {
153+
description: `Number of jobs to run concurrently`,
154+
validator: isString,
155+
});
156+
147157
include = Option.String('--include', {
148158
description: `List workspaces based on a glob pattern`,
149159
validator: isString,
@@ -178,6 +188,14 @@ module.exports = {
178188
extraArgs.push('--topological-dev');
179189
}
180190

191+
if (this.interlaced) {
192+
extraArgs.push('--interlaced');
193+
}
194+
195+
if (this.jobs) {
196+
extraArgs.push('--jobs', this.jobs.toString());
197+
}
198+
181199
const includes = workspaces.map((workspace) => workspace.manifest.name)
182200
.flatMap(({ scope, name }) => ['--include', `@${scope}/${name}`]);
183201

packages/examples/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
"lint:fix": "yarn lint:eslint --fix && yarn lint:misc --write",
3333
"lint:misc": "prettier --no-error-on-unmatched-pattern --log-level warn \"**/*.json\" \"**/*.md\" \"**/*.html\" \"!CHANGELOG.md\" \"!packages/**\" --ignore-path ../../.gitignore",
3434
"since-latest-release": "../../scripts/since-latest-release.sh",
35-
"start": "yarn workspaces foreach --worktree --parallel --verbose --interlaced --no-private --jobs unlimited run start",
35+
"start": "yarn workspaces filter --include 'packages/examples/packages/**' --parallel --interlaced --no-private --jobs unlimited run start",
3636
"start:test": "yarn start",
3737
"test": "jest --reporters=jest-silent-reporter",
3838
"test:clean": "jest --clearCache",

packages/test-snaps/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
"lint:fix": "yarn lint:eslint --fix && yarn lint:misc --write",
3333
"lint:misc": "prettier --no-error-on-unmatched-pattern --log-level warn \"**/*.json\" \"**/*.md\" \"**/*.html\" \"!CHANGELOG.md\" --ignore-path ../../.gitignore",
3434
"since-latest-release": "../../scripts/since-latest-release.sh",
35-
"start": "yarn workspaces foreach --parallel --verbose --interlaced --all --include \"@metamask/test-snaps\" --include \"@metamask/example-snaps\" run start:test",
35+
"start": "yarn workspaces foreach --parallel --interlaced --all --include \"@metamask/test-snaps\" --include \"@metamask/example-snaps\" run start:test",
3636
"start:test": "cross-env NODE_ENV=development webpack serve",
3737
"test": "jest --reporters=jest-silent-reporter",
3838
"test:clean": "jest --clearCache",

0 commit comments

Comments
 (0)