You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by an...@apache.org on 2014/12/02 16:06:27 UTC

[1/4] cordova-plugin-test-framework git commit: CB-8070 MedicReporter from plugin-test-framework incompatible with medic couch db structure. It's fixed.

Repository: cordova-plugin-test-framework
Updated Branches:
  refs/heads/master babbc4e90 -> a756992d1


CB-8070 MedicReporter from plugin-test-framework incompatible with medic couch db structure.
It's fixed.


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/commit/357b8993
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/tree/357b8993
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/diff/357b8993

Branch: refs/heads/master
Commit: 357b89932cf13e0bc035e36cfb65116f98bd6d2a
Parents: babbc4e
Author: maria.bukharina <ma...@akvelon.com>
Authored: Tue Nov 25 12:46:23 2014 +0300
Committer: maria.bukharina <ma...@akvelon.com>
Committed: Tue Nov 25 12:46:23 2014 +0300

----------------------------------------------------------------------
 www/assets/jasmine-medic.js |  9 ++++++---
 www/jasmine_helpers.js      | 24 ++++++++++++++----------
 www/medic.js                |  7 ++++---
 3 files changed, 24 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/blob/357b8993/www/assets/jasmine-medic.js
----------------------------------------------------------------------
diff --git a/www/assets/jasmine-medic.js b/www/assets/jasmine-medic.js
index 5673ecb..e14cb35 100644
--- a/www/assets/jasmine-medic.js
+++ b/www/assets/jasmine-medic.js
@@ -1,4 +1,4 @@
-/*
+/*
  *
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -99,7 +99,8 @@ jasmineRequire.MedicReporter = function(j$) {
       this.postTests({
           mobilespec:buildResults(),
           platform:(platformMap.hasOwnProperty(p) ? platformMap[p] : p),
-          version:p,
+          version: device.version.toLowerCase(),
+          sha: options.sha,
           timestamp:Math.round(Math.floor((new Date()).getTime() / 1000)),
           model:devmodel
           });
@@ -124,7 +125,9 @@ jasmineRequire.MedicReporter = function(j$) {
       console.log('posting tests');
 
       var xhr = new XMLHttpRequest();
-      xhr.open("POST", serverurl+'/result', true);
+      var doc_id = [options.sha, json.version, json.model].map(encodeURIComponent).join('__');
+      var doc_url = serverurl + '/mobilespec_results/' + doc_id;
+      xhr.open("PUT", doc_url, true);
       xhr.setRequestHeader("Content-Type","application/json")
       xhr.send(JSON.stringify(json));
     }

http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/blob/357b8993/www/jasmine_helpers.js
----------------------------------------------------------------------
diff --git a/www/jasmine_helpers.js b/www/jasmine_helpers.js
index 7d8690c..5c1203d 100644
--- a/www/jasmine_helpers.js
+++ b/www/jasmine_helpers.js
@@ -1,4 +1,4 @@
-/*
+/*
  *
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -81,13 +81,17 @@ function addJasmineReporters(jasmineInterface, jasmineEnv) {
     jasmineEnv.addReporter(jasmineInterface.htmlReporter);
 
     var medic = require('org.apache.cordova.test-framework.medic');
-    if (medic.enabled) {
-        jasmineRequire.medic(jasmineInterface.jasmine);
-        jasmineInterface.MedicReporter = new jasmineInterface.jasmine.MedicReporter({
-            env: jasmineEnv,
-            log: { logurl: medic.logurl }
-        });
-        jasmineInterface.MedicReporter.initialize();
-        jasmineEnv.addReporter(jasmineInterface.MedicReporter);
-    }
+    medic.load(function () {
+        if (medic.enabled) {
+            jasmineRequire.medic(jasmineInterface.jasmine);
+            jasmineInterface.MedicReporter = new jasmineInterface.jasmine.MedicReporter({
+                env: jasmineEnv,
+                log: { logurl: medic.logurl },
+                sha: medic.sha
+            });
+            jasmineInterface.MedicReporter.initialize();
+            jasmineEnv.addReporter(jasmineInterface.MedicReporter);
+        }
+    });
+    
 }

http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/blob/357b8993/www/medic.js
----------------------------------------------------------------------
diff --git a/www/medic.js b/www/medic.js
index 4c3a3c2..eef7750 100644
--- a/www/medic.js
+++ b/www/medic.js
@@ -1,4 +1,4 @@
-/*
+/*
  *
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -36,12 +36,13 @@ exports.log = function() {
 
 exports.load = function (callback) {
   var xhr = new XMLHttpRequest();
-  xhr.open("GET", "../medic.json", true);
+  xhr.open("GET", "medic.json", true);
   xhr.onload = function() {
     if (xhr.readyState == 4 && xhr.status == 200) {
       var cfg = JSON.parse(xhr.responseText);
-      exports.logurl = cfg.logurl;
+      exports.logurl = cfg.couchdb;
       exports.enabled = true;
+      exports.sha = cfg.sha;
       console.log('Loaded Medic Config: logurl=' + exports.logurl);
     }
     callback();


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org


[4/4] cordova-plugin-test-framework git commit: CB-8070 fixes incompatibility of medic plugin with Medic framework

Posted by an...@apache.org.
CB-8070 fixes incompatibility of medic plugin with Medic framework

Merge branch 'CB-8070'


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/commit/a756992d
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/tree/a756992d
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/diff/a756992d

Branch: refs/heads/master
Commit: a756992d15c6f825320af3de961c2a3b26bf0897
Parents: babbc4e 213a3e5
Author: Vladimir Kotikov <v-...@microsoft.com>
Authored: Tue Dec 2 18:03:59 2014 +0300
Committer: Vladimir Kotikov <v-...@microsoft.com>
Committed: Tue Dec 2 18:04:43 2014 +0300

----------------------------------------------------------------------
 www/assets/jasmine-medic.js | 7 +++++--
 www/jasmine_helpers.js      | 5 ++++-
 www/medic.js                | 3 ++-
 3 files changed, 11 insertions(+), 4 deletions(-)
----------------------------------------------------------------------



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org


[3/4] cordova-plugin-test-framework git commit: Removes duplicate medic loading (should be already loaded in main.init())

Posted by an...@apache.org.
Removes duplicate medic loading (should be already loaded in main.init())

* small compatibility fixes


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/commit/213a3e59
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/tree/213a3e59
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/diff/213a3e59

Branch: refs/heads/master
Commit: 213a3e597e04abcb15747d65509ae0d6ecdbeb4d
Parents: 80225da
Author: Vladimir Kotikov <v-...@microsoft.com>
Authored: Tue Dec 2 17:43:16 2014 +0300
Committer: Vladimir Kotikov <v-...@microsoft.com>
Committed: Tue Dec 2 17:43:16 2014 +0300

----------------------------------------------------------------------
 www/jasmine_helpers.js | 23 +++++++++++------------
 www/medic.js           |  4 ++--
 2 files changed, 13 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/blob/213a3e59/www/jasmine_helpers.js
----------------------------------------------------------------------
diff --git a/www/jasmine_helpers.js b/www/jasmine_helpers.js
index c556b00..7e0864d 100644
--- a/www/jasmine_helpers.js
+++ b/www/jasmine_helpers.js
@@ -81,17 +81,16 @@ function addJasmineReporters(jasmineInterface, jasmineEnv) {
     jasmineEnv.addReporter(jasmineInterface.htmlReporter);
 
     var medic = require('org.apache.cordova.test-framework.medic');
-    medic.load(function () {
-        if (medic.enabled) {
-            jasmineRequire.medic(jasmineInterface.jasmine);
-            jasmineInterface.MedicReporter = new jasmineInterface.jasmine.MedicReporter({
-                env: jasmineEnv,
-                log: { logurl: medic.logurl },
-                sha: medic.sha
-            });
-            jasmineInterface.MedicReporter.initialize();
-            jasmineEnv.addReporter(jasmineInterface.MedicReporter);
-        }
-    });
+
+    if (medic.enabled) {
+        jasmineRequire.medic(jasmineInterface.jasmine);
+        jasmineInterface.MedicReporter = new jasmineInterface.jasmine.MedicReporter({
+            env: jasmineEnv,
+            log: { logurl: medic.logurl },
+            sha: medic.sha
+        });
+        jasmineInterface.MedicReporter.initialize();
+        jasmineEnv.addReporter(jasmineInterface.MedicReporter);
+    }
     
 }

http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/blob/213a3e59/www/medic.js
----------------------------------------------------------------------
diff --git a/www/medic.js b/www/medic.js
index 8e1ec4c..a0a4f17 100644
--- a/www/medic.js
+++ b/www/medic.js
@@ -36,11 +36,11 @@ exports.log = function() {
 
 exports.load = function (callback) {
   var xhr = new XMLHttpRequest();
-  xhr.open("GET", "medic.json", true);
+  xhr.open("GET", "../medic.json", true);
   xhr.onload = function() {
     if (xhr.readyState == 4 && xhr.status == 200) {
       var cfg = JSON.parse(xhr.responseText);
-      exports.logurl = cfg.couchdb;
+      exports.logurl = cfg.couchdb || cfg.logurl;
       exports.enabled = true;
       exports.sha = cfg.sha;
       console.log('Loaded Medic Config: logurl=' + exports.logurl);


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org


[2/4] cordova-plugin-test-framework git commit: Fixed minor formatting bugs

Posted by an...@apache.org.
Fixed minor formatting bugs


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/commit/80225da9
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/tree/80225da9
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/diff/80225da9

Branch: refs/heads/master
Commit: 80225da9beef00cbf96c5eeaf944737b722e76b4
Parents: 357b899
Author: maria.bukharina <ma...@akvelon.com>
Authored: Tue Nov 25 12:50:46 2014 +0300
Committer: maria.bukharina <ma...@akvelon.com>
Committed: Tue Nov 25 12:50:46 2014 +0300

----------------------------------------------------------------------
 www/assets/jasmine-medic.js | 2 +-
 www/jasmine_helpers.js      | 2 +-
 www/medic.js                | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/blob/80225da9/www/assets/jasmine-medic.js
----------------------------------------------------------------------
diff --git a/www/assets/jasmine-medic.js b/www/assets/jasmine-medic.js
index e14cb35..49b0745 100644
--- a/www/assets/jasmine-medic.js
+++ b/www/assets/jasmine-medic.js
@@ -1,4 +1,4 @@
-/*
+/*
  *
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file

http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/blob/80225da9/www/jasmine_helpers.js
----------------------------------------------------------------------
diff --git a/www/jasmine_helpers.js b/www/jasmine_helpers.js
index 5c1203d..c556b00 100644
--- a/www/jasmine_helpers.js
+++ b/www/jasmine_helpers.js
@@ -1,4 +1,4 @@
-/*
+/*
  *
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file

http://git-wip-us.apache.org/repos/asf/cordova-plugin-test-framework/blob/80225da9/www/medic.js
----------------------------------------------------------------------
diff --git a/www/medic.js b/www/medic.js
index eef7750..8e1ec4c 100644
--- a/www/medic.js
+++ b/www/medic.js
@@ -1,4 +1,4 @@
-/*
+/*
  *
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org