-
-
Notifications
You must be signed in to change notification settings - Fork 539
Expand file tree
/
Copy pathterminology.spec.js
More file actions
41 lines (39 loc) · 962 Bytes
/
terminology.spec.js
File metadata and controls
41 lines (39 loc) · 962 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
const TextLintTester = require('textlint-tester');
const rule = require('../rules/terminology');
const tester = new TextLintTester();
tester.run('terminology', rule, {
valid: [
'메서드',
'서드 파티',
'예시',
'애플리케이션',
'함수 컴포넌트',
'생명주기',
],
invalid: [
{
text: '한 문장에 연속하는 용어 메소드와 메소드와 메쏘드를 테스트합니다.',
errors: [{index: 14}, {index: 19}, {index: 24}],
},
{
text: '서드파티와 써드파티와 써드 파티',
errors: [{index: 0}, {index: 6}, {index: 12}],
},
{
text: '예제',
errors: [{index: 0}],
},
{
text: '응용프로그램과 어플리케이션',
errors: [{index: 0}, {index: 8}],
},
{
text: '함수형 컴포넌트',
errors: [{index: 0}],
},
{
text: '라이프사이클',
errors: [{index: 0}],
},
],
});