Comparing version 1.2.1 to 1.3.0
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var duplicate_cli_argument_error_1 = require("./errors/duplicate-cli-argument-error"); | ||
@@ -3,0 +4,0 @@ var invalid_argument_names_error_1 = require("./errors/invalid-argument-names-error"); |
#! /usr/bin/env node | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var alsatian_cli_options_1 = require("./alsatian-cli-options"); | ||
@@ -4,0 +5,0 @@ var cli_test_runner_1 = require("./cli-test-runner"); |
@@ -37,2 +37,3 @@ "use strict"; | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var tap_bark_1 = require("tap-bark"); | ||
@@ -39,0 +40,0 @@ var alsatian_core_1 = require("../core/alsatian-core"); |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var extendo_error_1 = require("extendo-error"); | ||
@@ -8,0 +14,0 @@ var DuplicateCliArgumentError = (function (_super) { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var extendo_error_1 = require("extendo-error"); | ||
@@ -8,0 +14,0 @@ var InvalidArgumentNamesError = (function (_super) { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var extendo_error_1 = require("extendo-error"); | ||
@@ -8,0 +14,0 @@ var InvalidTimeoutValueError = (function (_super) { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var extendo_error_1 = require("extendo-error"); | ||
@@ -8,0 +14,0 @@ var MissingArgumentValueError = (function (_super) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
//# sourceMappingURL=index.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
//# sourceMappingURL=test-case.i.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
//# sourceMappingURL=test-fixture.i.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
//# sourceMappingURL=test.i.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var _1 = require("./"); | ||
@@ -3,0 +4,0 @@ exports.Expect = _1.Expect; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
//# sourceMappingURL=index.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
//# sourceMappingURL=setup-teardown-metadata.i.js.map |
@@ -8,2 +8,3 @@ // currently typing these values to string as literal causes | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var TEST_FIXTURE = "alsatian:test-fixture"; | ||
@@ -10,0 +11,0 @@ exports.TEST_FIXTURE = TEST_FIXTURE; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var async_setup_decorator_1 = require("./async-setup-decorator"); | ||
@@ -3,0 +4,0 @@ exports.AsyncSetup = async_setup_decorator_1.AsyncSetup; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _1 = require("../"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -3,0 +4,0 @@ var _metadata_keys_1 = require("./_metadata-keys"); |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var stringification_1 = require("../stringification"); | ||
@@ -8,0 +14,0 @@ var match_error_1 = require("./match-error"); |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var stringification_1 = require("../stringification"); | ||
@@ -8,0 +14,0 @@ var match_error_1 = require("./match-error"); |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var stringification_1 = require("../stringification"); | ||
@@ -8,0 +14,0 @@ var match_error_1 = require("./match-error"); |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var match_error_1 = require("./match-error"); | ||
@@ -8,0 +14,0 @@ var ErrorMatchError = (function (_super) { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var stringification_1 = require("../stringification"); | ||
@@ -8,0 +14,0 @@ var match_error_1 = require("./match-error"); |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var matchers_1 = require("../matchers"); | ||
@@ -8,0 +14,0 @@ var spying_1 = require("../spying"); |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var spying_1 = require("../spying"); | ||
@@ -28,3 +34,3 @@ var match_error_1 = require("./match-error"); | ||
else if (arg instanceof spying_1.TypeMatcher) { | ||
return "Any " + arg.type.name; | ||
return arg.stringify(); | ||
} | ||
@@ -31,0 +37,0 @@ else { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var match_error_1 = require("./match-error"); | ||
@@ -8,0 +14,0 @@ var GreaterThanMatchError = (function (_super) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var contents_match_error_1 = require("./contents-match-error"); | ||
@@ -3,0 +4,0 @@ exports.ContentsMatchError = contents_match_error_1.ContentsMatchError; |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var match_error_1 = require("./match-error"); | ||
@@ -8,0 +14,0 @@ var LessThanMatchError = (function (_super) { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var extendo_error_1 = require("extendo-error"); | ||
@@ -8,0 +14,0 @@ var MatchError = (function (_super) { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var match_error_1 = require("./match-error"); | ||
@@ -8,0 +14,0 @@ var PropertySetMatchError = (function (_super) { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var match_error_1 = require("./match-error"); | ||
@@ -8,0 +14,0 @@ var RegexMatchError = (function (_super) { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var match_error_1 = require("./match-error"); | ||
@@ -8,0 +14,0 @@ var TestTimeoutError = (function (_super) { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var match_error_1 = require("./match-error"); | ||
@@ -8,0 +14,0 @@ var TruthyMatchError = (function (_super) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
//# sourceMappingURL=index.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
//# sourceMappingURL=test-complete.i.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var errors_1 = require("./errors"); | ||
@@ -3,0 +4,0 @@ var spying_1 = require("./spying"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var FileRequirer = (function () { | ||
@@ -3,0 +4,0 @@ function FileRequirer() { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var Glob = require("glob"); | ||
@@ -3,0 +4,0 @@ var GlobHelper = (function () { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var expect_1 = require("./expect"); | ||
@@ -3,0 +4,0 @@ exports.Expect = expect_1.Expect; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var FunctionSpyCallCountMatcher = (function () { | ||
@@ -3,0 +4,0 @@ function FunctionSpyCallCountMatcher() { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var errors_1 = require("../errors"); | ||
@@ -3,0 +4,0 @@ var _1 = require("./"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var function_spy_call_count_matcher_1 = require("./function-spy-call-count-matcher"); | ||
@@ -3,0 +4,0 @@ exports.FunctionSpyCallCountMatcher = function_spy_call_count_matcher_1.FunctionSpyCallCountMatcher; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var SpyCallCountType; | ||
@@ -3,0 +4,0 @@ (function (SpyCallCountType) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var test_case_result_1 = require("./test-case-result"); | ||
@@ -3,0 +4,0 @@ exports.TestCaseResult = test_case_result_1.TestCaseResult; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var errors_1 = require("../errors"); | ||
@@ -3,0 +4,0 @@ var test_outcome_1 = require("./test-outcome"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var test_outcome_1 = require("./test-outcome"); | ||
@@ -3,0 +4,0 @@ var test_results_1 = require("./test-results"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var TestOutcome; | ||
@@ -3,0 +4,0 @@ (function (TestOutcome) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var test_case_result_1 = require("./test-case-result"); | ||
@@ -3,0 +4,0 @@ var test_outcome_1 = require("./test-outcome"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var test_fixture_results_1 = require("./test-fixture-results"); | ||
@@ -3,0 +4,0 @@ var test_outcome_1 = require("./test-outcome"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var test_item_1 = require("./test-item"); | ||
@@ -3,0 +4,0 @@ exports.TestItem = test_item_1.TestItem; |
@@ -37,2 +37,3 @@ "use strict"; | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var alsatian_core_1 = require("../alsatian-core"); | ||
@@ -39,0 +40,0 @@ var errors_1 = require("../errors"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var test_item_1 = require("./test-item"); | ||
@@ -3,0 +4,0 @@ var TestPlan = (function () { |
@@ -37,2 +37,3 @@ "use strict"; | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
require("reflect-metadata"); | ||
@@ -39,0 +40,0 @@ var alsatian_core_1 = require("../alsatian-core"); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var TestSetRunInfo = (function () { | ||
@@ -3,0 +4,0 @@ function TestSetRunInfo(_testPlan, _testSetResults, _timeout) { |
import { TypeMatcher } from "../spying"; | ||
export declare function Any(type: new (...args: Array<any>) => Object): TypeMatcher; | ||
export declare function Any<ExpectedType extends Object>(type: new (...args: Array<any>) => ExpectedType): TypeMatcher<ExpectedType>; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var spying_1 = require("../spying"); | ||
@@ -3,0 +4,0 @@ function Any(type) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var spying_1 = require("../spying"); | ||
@@ -3,0 +4,0 @@ var FunctionSpy = (function () { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var any_argument_1 = require("./any-argument"); | ||
@@ -3,0 +4,0 @@ exports.Any = any_argument_1.Any; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var spy_call_1 = require("./spy-call"); | ||
@@ -3,0 +4,0 @@ var PropertySpy = (function () { |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var spying_1 = require("../spying"); | ||
@@ -8,0 +14,0 @@ var RestorableFunctionSpy = (function (_super) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var spying_1 = require("../spying"); | ||
@@ -3,0 +4,0 @@ var SpyCall = (function () { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var spying_1 = require("../spying"); | ||
@@ -3,0 +4,0 @@ function SpyOnProperty(target, propertyName) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var spying_1 = require("../spying"); | ||
@@ -3,0 +4,0 @@ function SpyOn(target, functionName) { |
@@ -1,6 +0,14 @@ | ||
export declare class TypeMatcher { | ||
export declare class TypeMatcher<ExpectedType extends Object> { | ||
private _testers; | ||
private _type; | ||
readonly type: new (...args: any[]) => Object; | ||
constructor(type: new (...args: Array<any>) => Object); | ||
constructor(type: new (...args: Array<any>) => ExpectedType); | ||
test(value: any): boolean; | ||
stringify(): string; | ||
thatMatches(key: string, value: any): this; | ||
thatMatches(properties: Object): this; | ||
thatMatches(delegate: (argument: ExpectedType) => boolean): this; | ||
private _matchesKeyAndValue(key, value); | ||
private _matchesDelegate(delegate); | ||
private _matchesObjectLiteral(properties); | ||
} |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
function replacer(key, value) { | ||
if (typeof value === "function") { | ||
return value.toString(); | ||
} | ||
return value; | ||
} | ||
var TypeMatcher = (function () { | ||
function TypeMatcher(type) { | ||
var _this = this; | ||
this._testers = []; | ||
if (type === null || type === undefined) { | ||
@@ -8,2 +17,19 @@ throw new TypeError("type must not be null or undefined"); | ||
this._type = type; | ||
this._testers.push({ | ||
stringify: function () { return "Any " + _this.type.name; }, | ||
test: function (value) { | ||
if (type === String) { | ||
return typeof value === "string" || value instanceof _this._type; | ||
} | ||
else if (type === Number) { | ||
return typeof value === "number" || value instanceof _this._type; | ||
} | ||
else if (type === Boolean) { | ||
return typeof value === "boolean" || value instanceof _this._type; | ||
} | ||
else { | ||
return value instanceof _this._type; | ||
} | ||
} | ||
}); | ||
} | ||
@@ -18,15 +44,59 @@ Object.defineProperty(TypeMatcher.prototype, "type", { | ||
TypeMatcher.prototype.test = function (value) { | ||
if (this._type === String) { | ||
return typeof value === "string" || value instanceof this._type; | ||
return this._testers.every(function (tester) { return tester.test(value); }); | ||
}; | ||
TypeMatcher.prototype.stringify = function () { | ||
return this._testers.map(function (tester) { return tester.stringify(); }).join(" and "); | ||
}; | ||
TypeMatcher.prototype.thatMatches = function (first, second) { | ||
if (null === first || undefined === first) { | ||
throw new TypeError("thatMatches requires none-null or non-undefined argument"); | ||
} | ||
else if (this._type === Number) { | ||
return typeof value === "number" || value instanceof this._type; | ||
if (typeof first === "string") { | ||
return this._matchesKeyAndValue(first, second); | ||
} | ||
else if (this._type === Boolean) { | ||
return typeof value === "boolean" || value instanceof this._type; | ||
if (typeof first === "function") { | ||
return this._matchesDelegate(first); | ||
} | ||
else { | ||
return value instanceof this._type; | ||
if (typeof first === "object") { | ||
return this._matchesObjectLiteral(first); | ||
} | ||
throw new Error("Invalid arguments"); | ||
}; | ||
TypeMatcher.prototype._matchesKeyAndValue = function (key, value) { | ||
this._testers.push({ | ||
stringify: function () { return "with property '" + key + "' equal to '" + (JSON.stringify(value) || value.toString()) + "'"; }, | ||
test: function (v) { | ||
if (Object.getOwnPropertyNames(v).indexOf(key) < 0) { | ||
return false; | ||
} | ||
return v[key] === value; | ||
} | ||
}); | ||
return this; | ||
}; | ||
TypeMatcher.prototype._matchesDelegate = function (delegate) { | ||
this._testers.push({ | ||
stringify: function () { return "matches '" + delegate.toString() + "'"; }, | ||
test: function (v) { return delegate(v); } | ||
}); | ||
return this; | ||
}; | ||
TypeMatcher.prototype._matchesObjectLiteral = function (properties) { | ||
if (properties.constructor !== Object) { | ||
throw new TypeError("thatMatches requires value passed in to be an object literal"); | ||
} | ||
this._testers.push({ | ||
stringify: function () { return "matches '" + JSON.stringify(properties, replacer) + "'"; }, | ||
test: function (v) { | ||
var targetKeys = Object.getOwnPropertyNames(v); | ||
return Object.getOwnPropertyNames(properties).every(function (key) { | ||
if (targetKeys.indexOf(key) < 0) { | ||
return false; | ||
} | ||
return v[key] === properties[key]; | ||
}); | ||
} | ||
}); | ||
return this; | ||
}; | ||
return TypeMatcher; | ||
@@ -33,0 +103,0 @@ }()); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var spying_1 = require("../spying"); | ||
@@ -22,3 +23,3 @@ var ArgumentStringifier = (function () { | ||
else if (argument instanceof spying_1.TypeMatcher) { | ||
return "Any " + argument.type.name; | ||
return argument.stringify(); | ||
} | ||
@@ -25,0 +26,0 @@ else { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var argument_stringifier_1 = require("./argument-stringifier"); | ||
exports.ArgumentStringifier = argument_stringifier_1.ArgumentStringifier; | ||
//# sourceMappingURL=index.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var TestFixture = (function () { | ||
@@ -3,0 +4,0 @@ function TestFixture(description) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var _1 = require("./"); | ||
@@ -3,0 +4,0 @@ var alsatian_core_1 = require("./alsatian-core"); |
"use strict"; | ||
var __extends = (this && this.__extends) || function (d, b) { | ||
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
var __extends = (this && this.__extends) || (function () { | ||
var extendStatics = Object.setPrototypeOf || | ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; | ||
return function (d, b) { | ||
extendStatics(d, b); | ||
function __() { this.constructor = d; } | ||
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | ||
}; | ||
})(); | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var stream_1 = require("stream"); | ||
@@ -75,9 +81,9 @@ var errors_1 = require("./errors"); | ||
var _this = this; | ||
var testDescription = test.description; | ||
if (testCaseArguments !== undefined && testCaseArguments.length > 0) { | ||
testDescription += " ( " + testCaseArguments.map(function (argument) { | ||
return _this._getArgumentDescription(argument); | ||
}).join(", ") + " )"; | ||
if (testCaseArguments === undefined || testCaseArguments.length <= 0) { | ||
return test.description; | ||
} | ||
return testDescription; | ||
var formattedArguments = testCaseArguments | ||
.map(function (argument) { return _this._getArgumentDescription(argument); }) | ||
.join(", "); | ||
return test.description + " ( " + formattedArguments + " )"; | ||
}; | ||
@@ -84,0 +90,0 @@ TestOutputStream.prototype._getArgumentDescription = function (argument) { |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
var path = require("path"); | ||
@@ -3,0 +4,0 @@ var _1 = require("./"); |
{ | ||
"name": "alsatian", | ||
"version": "1.2.1", | ||
"version": "1.3.0", | ||
"description": "TypeScript and JavaScript testing framework for beautiful and readable tests", | ||
@@ -5,0 +5,0 @@ "author": "James Richford <=> (=)", |
@@ -13,4 +13,7 @@ <p id="banner" align="center"> | ||
<a href="https://travis-ci.org/alsatian-test/alsatian"> | ||
<img src="https://travis-ci.org/alsatian-test/alsatian.svg?branch=master" alt="Build Status" /> | ||
<img src="https://travis-ci.org/alsatian-test/alsatian.svg?branch=master" alt="Linux and OSX Build Status" /> | ||
</a> | ||
<a href="https://ci.appveyor.com/project/jamesrichford/alsatian"> | ||
<img src="https://ci.appveyor.com/api/projects/status/github/alsatian-test/alsatian?branch=master&svg=true" alt="Windows Build Status" /> | ||
</a> | ||
<a href="https://codeclimate.com/github/alsatian-test/alsatian"> | ||
@@ -17,0 +20,0 @@ <img src="https://codeclimate.com/github/alsatian-test/alsatian/badges/gpa.svg" alt="Code Climate" /> |
944222
186
3978
114