Skip to content

Commit 1317e3c

Browse files
authored
remove yarn usage in syntax highlight test (#2043)
1 parent d7cd467 commit 1317e3c

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

packages/svelte-vscode/syntaxes/README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,20 +8,20 @@ A good document to read in more detail about TextMate: https://www.apeth.com/non
88

99
## Developing the grammar
1010

11-
The grammar for pug and markdown is written in JSON. You can edit that directly. The main grammar is written in `yaml` because that's easier to structure than JSON. However, VS Code expects a JSON format. Therefore you need to run the `build:grammar` script afterwards. This will produce a JSON version of the file. Afterwards you need to restart your extension window for the changes to take effect.
11+
The grammar for pug and markdown is written in JSON. You can edit that directly. The main grammar is written in `yaml` because that's easier to structure than JSON. However, VS Code expects a JSON format. Therefore you need to run the `build:`grammar` script afterward. This will produce a JSON version of the file. Afterward, you need to restart your extension window for the changes to take effect.
1212

1313
### Snapshot test for the grammar
1414

15-
The snapshot test is run by [vscode-textmate-test](https://github.com/PanAeon/vscode-tmgrammar-test). The `test` command called a node script to build the argument and execute the `vscode-textmate-test` command. If you updated the svelte grammar file, Be sure to add the test cases to the `test/sample` directory.
15+
The snapshot test is run by [vscode-textmate-test](https://github.com/PanAeon/vscode-tmgrammar-test). The `test` command calls a node script to build the argument and execute the `vscode-textmate-test` command. If you updated the svelte grammar file, Be sure to add the test cases to the `test/sample` directory.
1616

17-
Then run the test to check if the update affect existing cases
17+
Then run the test to check if the update affects existing cases
1818

1919
```bash
20-
yarn test
20+
pnpm run test
2121
```
2222

23-
Update existing snapshot to match the changes
23+
Update existing snapshots to match the changes
2424

2525
```bash
26-
yarn test --updateSnapshot
26+
pnpm run test -- --updateSnapshot
2727
```

packages/svelte-vscode/test/grammar/test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ async function snapShotTest() {
4747
...extraArgs
4848
];
4949

50-
const code = await promisifySpawn(process.platform === 'win32' ? 'yarn.cmd' : 'yarn', args, {
50+
const code = await promisifySpawn(process.platform === 'win32' ? 'npx.cmd' : 'npx', args, {
5151
stdio: 'inherit'
5252
});
5353

0 commit comments

Comments
 (0)