diff --git a/tests/baselines/reference/nounusedTypeParameterConstraint.errors.txt b/tests/baselines/reference/nounusedTypeParameterConstraint.errors.txt new file mode 100644 index 00000000000..a5797b44d92 --- /dev/null +++ b/tests/baselines/reference/nounusedTypeParameterConstraint.errors.txt @@ -0,0 +1,12 @@ +tests/cases/compiler/test.ts(1,10): error TS6133: 'IEventSourcedEntity' is declared but never used. + + +==== tests/cases/compiler/bar.ts (0 errors) ==== + + export interface IEventSourcedEntity { } + +==== tests/cases/compiler/test.ts (1 errors) ==== + import { IEventSourcedEntity } from "./bar"; + ~~~~~~~~~~~~~~~~~~~ +!!! error TS6133: 'IEventSourcedEntity' is declared but never used. + export type DomainEntityConstructor = { new(): TEntity; }; \ No newline at end of file diff --git a/tests/baselines/reference/nounusedTypeParameterConstraint.js b/tests/baselines/reference/nounusedTypeParameterConstraint.js new file mode 100644 index 00000000000..aa403187f7a --- /dev/null +++ b/tests/baselines/reference/nounusedTypeParameterConstraint.js @@ -0,0 +1,14 @@ +//// [tests/cases/compiler/nounusedTypeParameterConstraint.ts] //// + +//// [bar.ts] + +export interface IEventSourcedEntity { } + +//// [test.ts] +import { IEventSourcedEntity } from "./bar"; +export type DomainEntityConstructor = { new(): TEntity; }; + +//// [bar.js] +"use strict"; +//// [test.js] +"use strict"; diff --git a/tests/cases/compiler/nounusedTypeParameterConstraint.ts b/tests/cases/compiler/nounusedTypeParameterConstraint.ts new file mode 100644 index 00000000000..d2c3a1677ee --- /dev/null +++ b/tests/cases/compiler/nounusedTypeParameterConstraint.ts @@ -0,0 +1,8 @@ +//@noUnusedLocals:true + +//@filename: bar.ts +export interface IEventSourcedEntity { } + +//@filename: test.ts +import { IEventSourcedEntity } from "./bar"; +export type DomainEntityConstructor = { new(): TEntity; }; \ No newline at end of file