Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Make test messages appears consistently as span.test-message #229

Merged
merged 1 commit into from

2 participants

@herby

In all three places, where output is created (message is one of parameters, details are produced, QUnit.log is called with details), let the message be always formatted in span class="text-message". Now, push does that, but nor ok not pushFailure does so.

@jzaefferer jzaefferer merged commit 329ee61 into jquery:master
@jzaefferer
Owner

Landed, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Apr 12, 2012
  1. @herby
This page is out of date. Refresh to see the latest.
Showing with 4 additions and 1 deletion.
  1. +4 −1 qunit/qunit.js
View
5 qunit/qunit.js
@@ -328,6 +328,7 @@ var QUnit = {
message: msg
};
msg = escapeInnerText(msg || (result ? "okay" : "failed"));
+ msg = '<span class="test-message">' + msg + "</span>";
if ( !result ) {
var source = sourceFromStacktrace(2);
if (source) {
@@ -687,7 +688,9 @@ extend(QUnit, {
result: false,
message: message
};
- var output = escapeInnerText(message);
+ message = escapeInnerText(message) || "error";
+ message = '<span class="test-message">' + message + "</span>";
+ var output = message;
if (source) {
details.source = source;
output += '<table><tr class="test-source"><th>Source: </th><td><pre>' + escapeInnerText(source) + '</pre></td></tr></table>';
Something went wrong with that request. Please try again.