Revert "Revert "Added the ability to associate trace information with failing specs""

This reverts commit fdad8849df.
This commit is contained in:
Steve Gravrock
2021-10-02 09:56:25 -07:00
parent 9c03d4d3e9
commit 47081258cd
12 changed files with 447 additions and 7 deletions

View File

@@ -397,4 +397,20 @@ getJasmineRequireObj().base = function(j$, jasmineGlobal) {
putativeSpy.calls instanceof j$.CallTracker
);
};
/**
* Logs a message for use in debugging. If the spec fails, trace messages
* will be included in the {@link SpecResult|result} passed to the
* reporter's specDone method.
*
* This method should be called only when a spec (including any associated
* beforeEach or afterEach functions) is running.
* @function
* @name jasmine.trace
* @since 3.10.0
* @param {String} msg - The message to log
*/
j$.trace = function(msg) {
j$.getEnv().trace(msg);
};
};