From dc3e67c73391ae5bf1895020278ea067894965ac Mon Sep 17 00:00:00 2001 From: Jason Kuhrt Date: Sat, 9 Nov 2024 10:05:48 -0500 Subject: [PATCH] add some test coverage --- src/language/__tests__/kind-test.ts | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 src/language/__tests__/kind-test.ts diff --git a/src/language/__tests__/kind-test.ts b/src/language/__tests__/kind-test.ts new file mode 100644 index 0000000000..4eaf75148b --- /dev/null +++ b/src/language/__tests__/kind-test.ts @@ -0,0 +1,29 @@ +/* eslint-disable @typescript-eslint/no-unused-expressions */ +import { describe, it } from 'mocha'; + +import { Kind } from '../index.js'; + +describe('Kind', () => { + it('is a term level namespace with term level enum members', () => { + const a: Kind.NAME = Kind.NAME; + a; + const b: Kind = Kind.NAME; + b; + const c: Kind = Kind.ARGUMENT; + c; + }); + it('is a type level namespace with type level enum members', () => { + // @ts-expect-error + const a: Kind.NAME = 'bad'; + a; + const b: Kind.NAME = 'Name'; + b; + // @ts-expect-error + const c: Kind = 'bad'; + c; + const d: Kind = 'Name'; + d; + const e: Kind = 'Argument'; + e; + }); +});