Don't double escape focus spec links.
- QueryString already escapes parameter values, no need to escape when passing them in from HtmlReporter. [finish #29578495]
This commit is contained in:
@@ -307,7 +307,7 @@ jasmineRequire.HtmlReporter = function(j$) {
|
||||
}
|
||||
|
||||
function specHref(result) {
|
||||
return addToExistingQueryString('spec', encodeURIComponent(result.fullName));
|
||||
return addToExistingQueryString('spec', result.fullName);
|
||||
}
|
||||
|
||||
function defaultQueryString(key, value) {
|
||||
|
||||
@@ -351,7 +351,7 @@ describe("New HtmlReporter", function() {
|
||||
var suiteDetail = outerSuite.childNodes[0];
|
||||
var suiteLink = suiteDetail.childNodes[0];
|
||||
expect(suiteLink.innerHTML).toEqual("A Suite");
|
||||
expect(suiteLink.getAttribute('href')).toEqual("?foo=bar&spec=A%20Suite");
|
||||
expect(suiteLink.getAttribute('href')).toEqual("?foo=bar&spec=A Suite");
|
||||
|
||||
var specs = outerSuite.childNodes[1];
|
||||
var spec = specs.childNodes[0];
|
||||
@@ -360,7 +360,7 @@ describe("New HtmlReporter", function() {
|
||||
|
||||
var specLink = spec.childNodes[0];
|
||||
expect(specLink.innerHTML).toEqual("with a spec");
|
||||
expect(specLink.getAttribute("href")).toEqual("?foo=bar&spec=A%20Suite%20with%20a%20spec");
|
||||
expect(specLink.getAttribute("href")).toEqual("?foo=bar&spec=A Suite with a spec");
|
||||
// expect(specLink.getAttribute("title")).toEqual("A Suite with a spec");
|
||||
});
|
||||
|
||||
@@ -616,7 +616,7 @@ describe("New HtmlReporter", function() {
|
||||
|
||||
var specLink = specDiv.childNodes[0];
|
||||
expect(specLink.getAttribute("title")).toEqual("a suite with a failing spec");
|
||||
expect(specLink.getAttribute("href")).toEqual("?foo=bar&spec=a%20suite%20with%20a%20failing%20spec");
|
||||
expect(specLink.getAttribute("href")).toEqual("?foo=bar&spec=a suite with a failing spec");
|
||||
|
||||
var message = failure.childNodes[1].childNodes[0];
|
||||
expect(message.getAttribute("class")).toEqual("result-message");
|
||||
|
||||
@@ -278,7 +278,7 @@ jasmineRequire.HtmlReporter = function(j$) {
|
||||
}
|
||||
|
||||
function specHref(result) {
|
||||
return addToExistingQueryString('spec', encodeURIComponent(result.fullName));
|
||||
return addToExistingQueryString('spec', result.fullName);
|
||||
}
|
||||
|
||||
function defaultQueryString(key, value) {
|
||||
|
||||
Reference in New Issue
Block a user