8000 Document that SpecResult#filename and SuiteResult#filename are wrong … · jasmine/jasmine@361640f · GitHub
[go: up one dir, main page]

Skip to content

Commit 361640f

Browse files
committed
Document that SpecResult#filename and SuiteResult#filename are wrong in some common scenarios
See: * #2016 * #1884
1 parent e5d46e8 commit 361640f

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

lib/jasmine-core/jasmine.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -919,6 +919,9 @@ getJasmineRequireObj().Spec = function(j$) {
919919
* @property {String} fullName - The full description including all ancestors of this spec.
920920
* @property {String|null} parentSuiteId - The ID of the suite containing this spec, or null if this spec is not in a describe().
921921
* @property {String} filename - The name of the file the spec was defined in.
922+
* Note: The value may be incorrect if zone.js is installed or
923+
* `it`/`fit`/`xit` have been replaced with versions that don't maintain the
924+
* same call stack height as the originals.
922925
* @property {ExpectationResult[]} failedExpectations - The list of expectations that failed during execution of this spec.
923926
* @property {ExpectationResult[]} passedExpectations - The list of expectations that passed during execution of this spec.
924927
* @property {ExpectationResult[]} deprecationWarnings - The list of deprecation warnings that occurred during execution this spec.
@@ -10478,6 +10481,9 @@ getJasmineRequireObj().Suite = function(j$) {
1047810481
* @property {String} fullName - The full description including all ancestors of this suite.
1047910482
* @property {String|null} parentSuiteId - The ID of the suite containing this suite, or null if this is not in another describe().
1048010483
* @property {String} filename - The name of the file the suite was defined in.
10484+
* Note: The value may be incorrect if zone.js is installed or
10485+
* `describe`/`fdescribe`/`xdescribe` have been replaced with versions that
10486+
* don't maintain the same call stack height as the originals.
1048110487
* @property {ExpectationResult[]} failedExpectations - The list of expectations that failed in an {@link afterAll} for this suite.
1048210488
* @property {ExpectationResult[]} deprecationWarnings - The list of deprecation warnings that occurred on this suite.
1048310489
* @property {String} status - Once the suite has completed, this string represents the pass/fail status of this suite.

src/core/Spec.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,9 @@ getJasmineRequireObj().Spec = function(j$) {
148148
* @property {String} fullName - The full description including all ancestors of this spec.
149149
* @property {String|null} parentSuiteId - The ID of the suite containing this spec, or null if this spec is not in a describe().
150150
* @property {String} filename - The name of the file the spec was defined in.
151+
* Note: The value may be incorrect if zone.js is installed or
152+
* `it`/`fit`/`xit` have been replaced with versions that don't maintain the
153+
* same call stack height as the originals.
151154
* @property {ExpectationResult[]} failedExpectations - The list of expectations that failed during execution of this spec.
152155
* @property {ExpectationResult[]} passedExpectations - The list of expectations that passed during execution of this spec.
153156
* @property {ExpectationResult[]} deprecationWarnings - The list of deprecation warnings that occurred during execution this spec.

src/core/Suite.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,9 @@ getJasmineRequireObj().Suite = function(j$) {
105105
* @property {String} fullName - The full description including all ancestors of this suite.
106106
* @property {String|null} parentSuiteId - The ID of the suite containing this suite, or null if this is not in another describe().
107107
* @property {String} filename - The name of the file the suite was defined in.
108+
* Note: The value may be incorrect if zone.js is installed or
109+
* `describe`/`fdescribe`/`xdescribe` have been replaced with versions that
110+
* don't maintain the same call stack height as the originals.
108111
* @property {ExpectationResult[]} failedExpectations - The list of expectations that failed in an {@link afterAll} for this suite.
109112
* @property {ExpectationResult[]} deprecationWarnings - The list of deprecation warnings that occurred on this suite.
110113
* @property {String} status - Once the suite has completed, this string represents the pass/fail status of this suite.

0 commit comments

Comments
 (0)
0