added definitions for assertion-error

This commit is contained in:
Bart van der Schoor
2014-04-01 01:08:27 +02:00
parent 6527fc4a3d
commit f5f60a4cb3
2 changed files with 30 additions and 0 deletions

View File

@@ -0,0 +1,15 @@
/// <reference path="assertion-error.d.ts" />
import AssertionError = require('assertion-error');
var e: AssertionError;
var str: string;
function foo () {
}
e = new AssertionError(str);
e = new AssertionError(str, {a:1, b2});
e = new AssertionError(str, {a:1, b2}, foo);

15
assertion-error/assertion-error.d.ts vendored Normal file
View File

@@ -0,0 +1,15 @@
// Type definitions for assertion-error 1.0 0
// Project: https://github.com/chaijs/assertion-error
// Definitions by: Bart van der Schoor <https://github.com/Bartvds>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
declare module 'assertion-error' {
class AssertionError implements Error {
constructor(message: string, props?: any, ssf?: Function);
name: string;
message: string;
showDiff: boolean;
stack: string;
}
export = AssertionError;
}