diff --git a/es6-error/es6-error-tests.ts b/es6-error/es6-error-tests.ts new file mode 100644 index 0000000000..a7f8ac6e25 --- /dev/null +++ b/es6-error/es6-error-tests.ts @@ -0,0 +1,15 @@ +// ES6 Error Test +// ================================================================================ +/// + +// Imports +// -------------------------------------------------------------------------------- +import * as ExtendableError from "es6-error" + +class TestError extends ExtendableError { + constructor (message: string = "TestError") { + super(message) + } +} + +throw new TestError("Test Message") diff --git a/es6-error/es6-error.d.ts b/es6-error/es6-error.d.ts new file mode 100644 index 0000000000..ce987f1a2f --- /dev/null +++ b/es6-error/es6-error.d.ts @@ -0,0 +1,8 @@ +// Type definitions for es6-error v4.0.0 +// Project: https://github.com/bjyoungblood/es6-error +// Definitions by: Karol Janyst +// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped + +declare module "es6-error" { + export = Error +}