You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ma...@apache.org on 2013/08/27 17:40:08 UTC
[1/2] spec commit: [CB-4568] Disable pop-up messages when running
test "XHR to within-package 11kb asset."
Updated Branches:
refs/heads/master 4b129f7e0 -> 376416a3c
[CB-4568] Disable pop-up messages when running test "XHR to within-package 11kb asset."
When fetching a file from the local file system, the result status of
XMLHttpRequest should be compared to 0 for success instead of 200.
This is because the file and ftp schemes do not use HTTP result codes.
FYI:https://developer.mozilla.org/es/docs/XMLHttpRequest/Usar_XMLHttpReq
uest
Project: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/commit/97b393b1
Tree: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/tree/97b393b1
Diff: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/diff/97b393b1
Branch: refs/heads/master
Commit: 97b393b17e50be174fadc1e5c6d6a4c7360e6a4e
Parents: 4b129f7
Author: lmnbeyond <lm...@gmail.com>
Authored: Wed Aug 14 19:54:21 2013 +0800
Committer: Max Woghiren <ma...@gmail.com>
Committed: Tue Aug 27 11:39:43 2013 -0400
----------------------------------------------------------------------
benchmarks/autobench.html | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/97b393b1/benchmarks/autobench.html
----------------------------------------------------------------------
diff --git a/benchmarks/autobench.html b/benchmarks/autobench.html
index 9104f05..445a46d 100644
--- a/benchmarks/autobench.html
+++ b/benchmarks/autobench.html
@@ -127,7 +127,8 @@ function bench() {
xhr.open("GET", "../LICENSE", true);
xhr.onreadystatechange = function() {
if (xhr.readyState == 4) {
- if (xhr.status == 200) {
+ // The result status is being compared to 0 for success instead of 200. This is because the file and ftp schemes do not use HTTP result codes.
+ if (xhr.status == 0 && xhr.responseText.length > 0) {
next();
} else {
alert('There was a problem during XHR file read!');
[2/2] spec commit: Add backButton for autobench.html
Posted by ma...@apache.org.
Add backButton for autobench.html
---Show backButton when tests are done
---Since "licensecontents.js" is non-exist, remove the reference to it
Project: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/commit/376416a3
Tree: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/tree/376416a3
Diff: http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/diff/376416a3
Branch: refs/heads/master
Commit: 376416a3cf8589387b8c1fc372b44c8fa0f84089
Parents: 97b393b
Author: lmnbeyond <lm...@gmail.com>
Authored: Wed Aug 14 20:04:14 2013 +0800
Committer: Max Woghiren <ma...@gmail.com>
Committed: Tue Aug 27 11:39:52 2013 -0400
----------------------------------------------------------------------
benchmarks/autobench.html | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-mobile-spec/blob/376416a3/benchmarks/autobench.html
----------------------------------------------------------------------
diff --git a/benchmarks/autobench.html b/benchmarks/autobench.html
index 445a46d..1a909fb 100644
--- a/benchmarks/autobench.html
+++ b/benchmarks/autobench.html
@@ -27,7 +27,6 @@
<link rel="stylesheet" href="../master.css" type="text/css" media="screen" title="no title" charset="utf-8">
<script type="text/javascript" charset="utf-8" src="../cordova-incl.js"></script>
<script type="text/javascript" charset="utf-8" src="uubench.js"></script>
- <script type="text/javascript" charset="utf-8" src="licensecontents.js"></script>
<script>
var exec = cordova.require('cordova/exec');
var temp, pers, LICENSE_CONTENTS;
@@ -62,6 +61,7 @@
min: 2000, // each benchmark should run for at least 2000ms
done:function() {
$('loading').innerHTML = "Benchmarks complete.";
+ $('backBtn').style.display="block";
}
});
var results = {};
@@ -176,7 +176,7 @@ function bench() {
</script>
</head>
- <body>
+ <body id="stage" class="theme">
<h1>Auto-Benchmarks</h1>
<h2 id="loading"></h2>
<table>
@@ -189,5 +189,6 @@ function bench() {
<tbody id="table-results">
</tbody>
</table>
+ <h2> </h2><a href="javascript:" class="backBtn" style="display:none" id='backBtn' onclick="backHome();">Back</a><br>
</body>
</html>