Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit92a9060

Browse files
committed
Update Jest configuration file.
1 parentbb86b30 commit92a9060

File tree

4 files changed

+32
-6
lines changed

4 files changed

+32
-6
lines changed

‎README.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,14 +174,22 @@ tree is being used.
174174
npm install
175175
```
176176

177+
**Run ESLint**
178+
179+
You may want to run it to check code quality.
180+
181+
```
182+
npm run lint
183+
```
184+
177185
**Run all tests**
178186
```
179187
npm test
180188
```
181189

182190
**Run tests by name**
183191
```
184-
npm test ---t'LinkedList'
192+
npm test -- 'LinkedList'
185193
```
186194

187195
**Playground**
@@ -192,7 +200,7 @@ tests for it in `./src/playground/__test__/playground.test.js`.
192200
Then just simply run the following command to test if your playground code works as expected:
193201

194202
```
195-
npm test ---t'playground'
203+
npm test -- 'playground'
196204
```
197205

198206
##Useful Information

‎README.zh-CN.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ npm test
147147

148148
**按照名称执行测试**
149149
```
150-
npm test ---t'LinkedList'
150+
npm test -- 'LinkedList'
151151
```
152152

153153
**Playground**
@@ -157,7 +157,7 @@ npm test -- -t 'LinkedList'
157157
然后,只需运行以下命令来测试你的 Playground 是否按无误:
158158

159159
```
160-
npm test ---t'playground'
160+
npm test -- 'playground'
161161
```
162162

163163
##有用的信息

‎README.zh-TW.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ npm test
145145

146146
**以名稱執行該測試**
147147
```
148-
npm test ---t'LinkedList'
148+
npm test -- 'LinkedList'
149149
```
150150
**練習場**
151151

@@ -154,7 +154,7 @@ npm test -- -t 'LinkedList'
154154
接著直接執行下列的指令來測試你練習的 code 是否如預期運作:
155155

156156
```
157-
npm test ---t'playground'
157+
npm test -- 'playground'
158158
```
159159

160160
##有用的資訊

‎jest.config.js

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,23 @@
11
module.exports={
2+
// The bail config option can be used here to have Jest stop running tests after
3+
// the first failure.
4+
bail:false,
5+
6+
// Indicates whether each individual test should be reported during the run.
27
verbose:false,
8+
9+
// Indicates whether the coverage information should be collected while executing the test
310
collectCoverage:false,
11+
12+
// The directory where Jest should output its coverage files.
413
coverageDirectory:'./coverage/',
14+
15+
// If the test path matches any of the patterns, it will be skipped.
16+
testPathIgnorePatterns:['<rootDir>/node_modules/'],
17+
18+
// If the file path matches any of the patterns, coverage information will be skipped.
19+
coveragePathIgnorePatterns:['<rootDir>/node_modules/'],
20+
21+
// The pattern Jest uses to detect test files.
22+
testRegex:'(/__tests__/.*|(\\.|/)(test|spec))\\.jsx?$',
523
};

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp