You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by pu...@apache.org on 2015/06/17 01:08:04 UTC

[1/4] cordova-plugin-console git commit: CB-9191 Add basic test

Repository: cordova-plugin-console
Updated Branches:
  refs/heads/master 0e7d464c7 -> d58f218b9


CB-9191 Add basic test


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-console/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-console/commit/38cc8f79
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-console/tree/38cc8f79
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-console/diff/38cc8f79

Branch: refs/heads/master
Commit: 38cc8f7957c50886157e435d1381ce3f238d28ef
Parents: 0e7d464
Author: Jesse MacFadyen <pu...@gmail.com>
Authored: Tue Jun 16 13:57:22 2015 -0700
Committer: Jesse MacFadyen <pu...@gmail.com>
Committed: Tue Jun 16 13:57:22 2015 -0700

----------------------------------------------------------------------
 tests/plugin.xml | 31 +++++++++++++++++++++++++++++++
 tests/tests.js   | 31 +++++++++++++++++++++++++++++++
 2 files changed, 62 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-console/blob/38cc8f79/tests/plugin.xml
----------------------------------------------------------------------
diff --git a/tests/plugin.xml b/tests/plugin.xml
new file mode 100644
index 0000000..efd254e
--- /dev/null
+++ b/tests/plugin.xml
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+
+<plugin xmlns="http://apache.org/cordova/ns/plugins/1.0"
+    xmlns:rim="http://www.blackberry.com/ns/widgets"
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    id="cordova-plugin-console-tests"
+    version="1.0.1-dev">
+    <name>Cordova Console Plugin Tests</name>
+    <license>Apache 2.0</license>
+
+    <js-module src="tests.js" name="tests">
+    </js-module>
+</plugin>

http://git-wip-us.apache.org/repos/asf/cordova-plugin-console/blob/38cc8f79/tests/tests.js
----------------------------------------------------------------------
diff --git a/tests/tests.js b/tests/tests.js
new file mode 100644
index 0000000..c5a92a7
--- /dev/null
+++ b/tests/tests.js
@@ -0,0 +1,31 @@
+/*
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ *
+*/
+
+exports.defineAutoTests = function () {
+      describe("Console", function () {
+        it("console.spec.1 should exist", function() {
+          expect(window.console).toBeDefined();
+      });
+};
+
+exports.defineManualTests = function (contentEl, createActionButton) {
+  
+};


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


[2/4] cordova-plugin-console git commit: add a couple tests

Posted by pu...@apache.org.
add a couple tests


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

Branch: refs/heads/master
Commit: e888a5b2580c1adf5a50d28692179d19d93b9ef0
Parents: 38cc8f7
Author: Jesse MacFadyen <pu...@gmail.com>
Authored: Tue Jun 16 14:05:17 2015 -0700
Committer: Jesse MacFadyen <pu...@gmail.com>
Committed: Tue Jun 16 14:05:17 2015 -0700

----------------------------------------------------------------------
 tests/tests.js | 28 +++++++++++++++++++++++-----
 1 file changed, 23 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-console/blob/e888a5b2/tests/tests.js
----------------------------------------------------------------------
diff --git a/tests/tests.js b/tests/tests.js
index c5a92a7..61aab6b 100644
--- a/tests/tests.js
+++ b/tests/tests.js
@@ -19,13 +19,31 @@
  *
 */
 
-exports.defineAutoTests = function () {
+exports = {
+    defineAutoTests:function () {
       describe("Console", function () {
         it("console.spec.1 should exist", function() {
-          expect(window.console).toBeDefined();
+            expect(window.console).toBeDefined();
+        });
+        
+        it("console.spec.2 has required methods",function(){
+            expect(window.console.log).toBeDefined();
+            expect(typeof window.console.log).toBe('function');
+            
+            expect(window.console.warn).toBeDefined();
+            expect(typeof window.console.warn).toBe('function');
+            
+            expect(window.console.error).toBeDefined();
+            expect(typeof window.console.error).toBe('function');
+            
+            expect(window.console.info).toBeDefined();
+            expect(typeof window.console.info).toBe('function');
+        });
+        
       });
-};
+    },
 
-exports.defineManualTests = function (contentEl, createActionButton) {
-  
+    defineManualTests:function (contentEl, createActionButton) {
+      
+    }
 };


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


[4/4] cordova-plugin-console git commit: move logger.js and console-via-logger.js to common modules, instead of the numerous repeats that were there.

Posted by pu...@apache.org.
move logger.js and console-via-logger.js to common modules, instead of the numerous repeats that were there.


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

Branch: refs/heads/master
Commit: d58f218b9149d362ebb0b8ce697cf403569d14cd
Parents: b489956
Author: Jesse MacFadyen <pu...@gmail.com>
Authored: Tue Jun 16 16:01:23 2015 -0700
Committer: Jesse MacFadyen <pu...@gmail.com>
Committed: Tue Jun 16 16:01:23 2015 -0700

----------------------------------------------------------------------
 plugin.xml | 51 ++++++++-------------------------------------------
 1 file changed, 8 insertions(+), 43 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-console/blob/d58f218b/plugin.xml
----------------------------------------------------------------------
diff --git a/plugin.xml b/plugin.xml
index 34c8b1f..fa87b4e 100644
--- a/plugin.xml
+++ b/plugin.xml
@@ -29,6 +29,14 @@
     <repo>https://git-wip-us.apache.org/repos/asf/cordova-plugin-console.git</repo>
     <issue>https://issues.apache.org/jira/browse/CB/component/12320644</issue>
 
+    <js-module src="www/logger.js" name="logger">
+        <clobbers target="cordova.logger" />
+    </js-module>
+    
+    <js-module src="www/console-via-logger.js" name="console">
+        <clobbers target="console" />
+    </js-module>
+        
     <!-- ios -->
     <platform name="ios">
 
@@ -38,14 +46,6 @@
 		</feature>
         </config-file>
 
-        <js-module src="www/console-via-logger.js" name="console">
-            <clobbers target="console" />
-        </js-module>
-
-        <js-module src="www/logger.js" name="logger">
-            <clobbers target="cordova.logger" />
-        </js-module>
-
 	<header-file src="src/ios/CDVLogger.h" />
 	<source-file src="src/ios/CDVLogger.m" />
 
@@ -53,13 +53,6 @@
 
     <!-- ubuntu -->
     <platform name="ubuntu">
-        <js-module src="www/console-via-logger.js" name="console">
-            <clobbers target="console" />
-        </js-module>
-
-        <js-module src="www/logger.js" name="logger">
-            <clobbers target="cordova.logger" />
-        </js-module>
 
         <header-file src="src/ubuntu/console.h" />
         <source-file src="src/ubuntu/console.cpp" />
@@ -74,14 +67,6 @@
             </feature>
         </config-file>
 
-        <js-module src="www/console-via-logger.js" name="console">
-            <clobbers target="console" />
-        </js-module>
-
-        <js-module src="www/logger.js" name="logger">
-            <clobbers target="cordova.logger" />
-        </js-module>
-
         <source-file src="src/wp/DebugConsole.cs" />
     </platform>
 
@@ -93,35 +78,15 @@
             </feature>
         </config-file>
 
-        <js-module src="www/console-via-logger.js" name="console">
-            <clobbers target="console" />
-        </js-module>
-
-        <js-module src="www/logger.js" name="logger">
-            <clobbers target="cordova.logger" />
-        </js-module>
-
         <source-file src="src/wp/DebugConsole.cs" />
     </platform>
 
     <!-- windows8 -->
     <platform name="windows8">
-        <js-module src="www/logger.js" name="logger">
-            <clobbers target="cordova.logger" />
-        </js-module>
-        <js-module src="www/console-via-logger.js" name="console">
-            <clobbers target="console" />
-        </js-module>
     </platform>
 
     <!-- Windows universal platform -->
     <platform name="windows">
-        <js-module src="www/logger.js" name="logger">
-            <clobbers target="cordova.logger" />
-        </js-module>
-        <js-module src="www/console-via-logger.js" name="console">
-            <clobbers target="console" />
-        </js-module>
     </platform>
 
 </plugin>


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


[3/4] cordova-plugin-console git commit: clean up tests, info is below log level so it does not exist by default.

Posted by pu...@apache.org.
clean up tests, info is below log level so it does not exist by default.


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

Branch: refs/heads/master
Commit: b4899565bed6f9267856d57f48e6b2672c55de56
Parents: e888a5b
Author: Jesse MacFadyen <pu...@gmail.com>
Authored: Tue Jun 16 16:00:23 2015 -0700
Committer: Jesse MacFadyen <pu...@gmail.com>
Committed: Tue Jun 16 16:00:23 2015 -0700

----------------------------------------------------------------------
 tests/tests.js | 44 +++++++++++++++++++-------------------------
 1 file changed, 19 insertions(+), 25 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-console/blob/b4899565/tests/tests.js
----------------------------------------------------------------------
diff --git a/tests/tests.js b/tests/tests.js
index 61aab6b..6479e41 100644
--- a/tests/tests.js
+++ b/tests/tests.js
@@ -19,31 +19,25 @@
  *
 */
 
-exports = {
-    defineAutoTests:function () {
-      describe("Console", function () {
-        it("console.spec.1 should exist", function() {
-            expect(window.console).toBeDefined();
-        });
+exports.defineAutoTests = function () {
+  describe("Console", function () {
+    it("console.spec.1 should exist", function() {
+        expect(window.console).toBeDefined();
+    });
+    
+    it("console.spec.2 has required methods log|warn|error", function(){
+        expect(window.console.log).toBeDefined();
+        expect(typeof window.console.log).toBe('function');
         
-        it("console.spec.2 has required methods",function(){
-            expect(window.console.log).toBeDefined();
-            expect(typeof window.console.log).toBe('function');
-            
-            expect(window.console.warn).toBeDefined();
-            expect(typeof window.console.warn).toBe('function');
-            
-            expect(window.console.error).toBeDefined();
-            expect(typeof window.console.error).toBe('function');
-            
-            expect(window.console.info).toBeDefined();
-            expect(typeof window.console.info).toBe('function');
-        });
+        expect(window.console.warn).toBeDefined();
+        expect(typeof window.console.warn).toBe('function');
         
-      });
-    },
-
-    defineManualTests:function (contentEl, createActionButton) {
-      
-    }
+        expect(window.console.error).toBeDefined();
+        expect(typeof window.console.error).toBe('function');                   
+        
+    });
+    
+  });
 };
+
+exports.defineManualTests = function (contentEl, createActionButton) {};


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