提交 7089a818 编写于 作者: M mindless

[FIXED HUDSON-1544] add jsStringEscape in case test name has quote or backslash.

also set text/plain content type on ajax summary response so browser doesn't try
to parse response (firefox 3.6 showed error in console with text/html).


git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@27444 71c3de6d-444a-0410-be80-ed276b4c234a
上级 c477e4a0
<!--
The MIT License
Copyright (c) 2004-2009, Sun Microsystems, Inc., Tom Huybrechts
Copyright (c) 2004-2010, Sun Microsystems, Inc., Tom Huybrechts
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
......@@ -25,7 +25,8 @@ THE SOFTWARE.
<!-- this is loaded on demand in the failed test results summary -->
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler" xmlns:d="jelly:define"
xmlns:l="/lib/layout" xmlns:t="/lib/hudson" xmlns:f="/lib/form">
<j:choose>
<st:contentType value="text/plain"/>
<j:choose>
<j:when test="${it.errorDetails!=null}">
<h3>${%Error Details}</h3>
<pre><st:out value="${it.errorDetails}"/></pre>
......@@ -36,5 +37,5 @@ THE SOFTWARE.
<pre><st:out value="${it.errorStackTrace}"/></pre>
</j:if>
</j:otherwise>
</j:choose>
</j:choose>
</j:jelly>
<!--
The MIT License
Copyright (c) 2004-2009, Sun Microsystems, Inc., Kohsuke Kawaguchi, id:cactusman, Tom Huybrechts, Yahoo!, Inc.
Copyright (c) 2004-2010, Sun Microsystems, Inc., Kohsuke Kawaguchi, id:cactusman, Tom Huybrechts, Yahoo!, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
......@@ -57,9 +57,9 @@ THE SOFTWARE.
<tr>
<td class="pane">
<a id="test-${f.fullName}-showlink" href="#"
onclick='javascript:showStackTrace("test-${f.fullName}","${f.getRelativePathFrom(it)}/summary")'>&gt;&gt;&gt;</a>
onclick="javascript:showStackTrace('test-${h.jsStringEscape(f.fullName)}','${f.getRelativePathFrom(it)}/summary')">&gt;&gt;&gt;</a>
<a id="test-${f.fullName}-hidelink" href="#" style="display:none"
onclick='javascript:hideStackTrace("test-${f.fullName}")'>&lt;&lt;&lt;</a>
onclick="javascript:hideStackTrace('test-${h.jsStringEscape(f.fullName)}')">&lt;&lt;&lt;</a>
<st:nbsp/>
<a href="${f.getRelativePathFrom(it)}"><st:out value="${f.fullName}"/></a>
<st:nbsp/>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册