Improved jsdocs for user-specified spec/suite properties
This commit is contained in:
@@ -716,7 +716,7 @@ getJasmineRequireObj().Spec = function(j$) {
|
||||
* @property {String} pendingReason - If the spec is {@link pending}, this will be the reason.
|
||||
* @property {String} status - Once the spec has completed, this string represents the pass/fail status of this spec.
|
||||
* @property {number} duration - The time in ms used by the spec execution, including any before/afterEach.
|
||||
* @property {Object} properties - user-supplied key-value pairs.
|
||||
* @property {Object} properties - User-supplied properties, if any, that were set using {@link Env#setSpecProperty}
|
||||
*/
|
||||
this.result = {
|
||||
id: this.id,
|
||||
@@ -2075,6 +2075,14 @@ getJasmineRequireObj().Env = function(j$) {
|
||||
return spec;
|
||||
};
|
||||
|
||||
/**
|
||||
* Sets a user-defined property that will be provided to reporters as part of {@link SpecResult#properties}
|
||||
* @name Env#setSpecProperty
|
||||
* @since 3.6.0
|
||||
* @function
|
||||
* @param {String} key The name of the property
|
||||
* @param {*} value The value of the property
|
||||
*/
|
||||
this.setSpecProperty = function(key, value) {
|
||||
if (!currentRunnable() || currentRunnable() == currentSuite()) {
|
||||
throw new Error(
|
||||
@@ -2084,6 +2092,14 @@ getJasmineRequireObj().Env = function(j$) {
|
||||
currentRunnable().setSpecProperty(key, value);
|
||||
};
|
||||
|
||||
/**
|
||||
* Sets a user-defined property that will be provided to reporters as part of {@link SuiteResult#properties}
|
||||
* @name Env#setSuiteProperty
|
||||
* @since 3.6.0
|
||||
* @function
|
||||
* @param {String} key The name of the property
|
||||
* @param {*} value The value of the property
|
||||
*/
|
||||
this.setSuiteProperty = function(key, value) {
|
||||
if (!currentSuite()) {
|
||||
throw new Error(
|
||||
@@ -8373,7 +8389,7 @@ getJasmineRequireObj().Suite = function(j$) {
|
||||
* @property {Expectation[]} deprecationWarnings - The list of deprecation warnings that occurred on this suite.
|
||||
* @property {String} status - Once the suite has completed, this string represents the pass/fail status of this suite.
|
||||
* @property {number} duration - The time in ms for Suite execution, including any before/afterAll, before/afterEach.
|
||||
* @property {Object} properties - user-supplied key-value pairs.
|
||||
* @property {Object} properties - User-supplied properties, if any, that were set using {@link Env#setSuiteProperty}
|
||||
*/
|
||||
this.result = {
|
||||
id: this.id,
|
||||
|
||||
@@ -1124,6 +1124,14 @@ getJasmineRequireObj().Env = function(j$) {
|
||||
return spec;
|
||||
};
|
||||
|
||||
/**
|
||||
* Sets a user-defined property that will be provided to reporters as part of {@link SpecResult#properties}
|
||||
* @name Env#setSpecProperty
|
||||
* @since 3.6.0
|
||||
* @function
|
||||
* @param {String} key The name of the property
|
||||
* @param {*} value The value of the property
|
||||
*/
|
||||
this.setSpecProperty = function(key, value) {
|
||||
if (!currentRunnable() || currentRunnable() == currentSuite()) {
|
||||
throw new Error(
|
||||
@@ -1133,6 +1141,14 @@ getJasmineRequireObj().Env = function(j$) {
|
||||
currentRunnable().setSpecProperty(key, value);
|
||||
};
|
||||
|
||||
/**
|
||||
* Sets a user-defined property that will be provided to reporters as part of {@link SuiteResult#properties}
|
||||
* @name Env#setSuiteProperty
|
||||
* @since 3.6.0
|
||||
* @function
|
||||
* @param {String} key The name of the property
|
||||
* @param {*} value The value of the property
|
||||
*/
|
||||
this.setSuiteProperty = function(key, value) {
|
||||
if (!currentSuite()) {
|
||||
throw new Error(
|
||||
|
||||
@@ -48,7 +48,7 @@ getJasmineRequireObj().Spec = function(j$) {
|
||||
* @property {String} pendingReason - If the spec is {@link pending}, this will be the reason.
|
||||
* @property {String} status - Once the spec has completed, this string represents the pass/fail status of this spec.
|
||||
* @property {number} duration - The time in ms used by the spec execution, including any before/afterEach.
|
||||
* @property {Object} properties - user-supplied key-value pairs.
|
||||
* @property {Object} properties - User-supplied properties, if any, that were set using {@link Env#setSpecProperty}
|
||||
*/
|
||||
this.result = {
|
||||
id: this.id,
|
||||
|
||||
@@ -27,7 +27,7 @@ getJasmineRequireObj().Suite = function(j$) {
|
||||
* @property {Expectation[]} deprecationWarnings - The list of deprecation warnings that occurred on this suite.
|
||||
* @property {String} status - Once the suite has completed, this string represents the pass/fail status of this suite.
|
||||
* @property {number} duration - The time in ms for Suite execution, including any before/afterAll, before/afterEach.
|
||||
* @property {Object} properties - user-supplied key-value pairs.
|
||||
* @property {Object} properties - User-supplied properties, if any, that were set using {@link Env#setSuiteProperty}
|
||||
*/
|
||||
this.result = {
|
||||
id: this.id,
|
||||
|
||||
Reference in New Issue
Block a user