diff --git a/nodemailer-stub-transport/nodemailer-stub-transport-tests.ts b/nodemailer-stub-transport/nodemailer-stub-transport-tests.ts
new file mode 100644
index 0000000000..ab29823588
--- /dev/null
+++ b/nodemailer-stub-transport/nodemailer-stub-transport-tests.ts
@@ -0,0 +1,8 @@
+///
+
+import nodemailer = require("nodemailer");
+import stubTransport = require("nodemailer-stub-transport");
+
+var transport = nodemailer.createTransport(stubTransport());
+nodemailer.createTransport(stubTransport({ error: new Error('Invalid recipient') }));
+transport = nodemailer.createTransport(stubTransport({ keepBcc: true }));
diff --git a/nodemailer-stub-transport/nodemailer-stub-transport.d.ts b/nodemailer-stub-transport/nodemailer-stub-transport.d.ts
new file mode 100644
index 0000000000..36eca75240
--- /dev/null
+++ b/nodemailer-stub-transport/nodemailer-stub-transport.d.ts
@@ -0,0 +1,38 @@
+// Type definitions for nodemailer-stub-transport v1.1.0
+// Project: https://github.com/andris9/nodemailer-stub-transport
+// Definitions by: Cyril Schumacher
+// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
+
+///
+
+declare module "nodemailer-stub-transport" {
+ import * as nodemailer from "nodemailer";
+
+ namespace StubTransportStatic {
+ /**
+ * Options.
+ * @interface
+ */
+ export interface Options {
+ /**
+ * Specifies a custom error.
+ * @type {any}
+ */
+ error?: any;
+
+ /**
+ * Value that indicates if the BCC addresses must be included in generated message.
+ * @type {boolean}
+ */
+ keepBcc?: boolean;
+ }
+ }
+
+ /**
+ * Creates a stub transport.
+ * @param {Options} [options] Options.
+ * @return {Transport} The stub transport.
+ */
+ function stubTransport(options?: StubTransportStatic.Options): nodemailer.Transport;
+ export = stubTransport;
+}