Skip to content

Commit dc3e67c

Browse files
committed
add some test coverage
1 parent df5e4f6 commit dc3e67c

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

src/language/__tests__/kind-test.ts

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
/* eslint-disable @typescript-eslint/no-unused-expressions */
2+
import { describe, it } from 'mocha';
3+
4+
import { Kind } from '../index.js';
5+
6+
describe('Kind', () => {
7+
it('is a term level namespace with term level enum members', () => {
8+
const a: Kind.NAME = Kind.NAME;
9+
a;
10+
const b: Kind = Kind.NAME;
11+
b;
12+
const c: Kind = Kind.ARGUMENT;
13+
c;
14+
});
15+
it('is a type level namespace with type level enum members', () => {
16+
// @ts-expect-error
17+
const a: Kind.NAME = 'bad';
18+
a;
19+
const b: Kind.NAME = 'Name';
20+
b;
21+
// @ts-expect-error
22+
const c: Kind = 'bad';
23+
c;
24+
const d: Kind = 'Name';
25+
d;
26+
const e: Kind = 'Argument';
27+
e;
28+
});
29+
});

0 commit comments

Comments
 (0)