cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1453958 - in /cxf/trunk/rt/javascript: javascript-rt/src/main/resources/org/apache/cxf/javascript/cxf-utils.js javascript-tests/src/test/java/org/apache/cxf/javascript/JavascriptTestUtilities.java
Date Thu, 07 Mar 2013 17:01:54 GMT
Author: dkulp
Date: Thu Mar  7 17:01:53 2013
New Revision: 1453958

URL: http://svn.apache.org/r1453958
Log:
[CXF-4881] Updates to the js tests to make the tracer act directly as a function which is
what typeof returns.

Modified:
    cxf/trunk/rt/javascript/javascript-rt/src/main/resources/org/apache/cxf/javascript/cxf-utils.js
    cxf/trunk/rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/JavascriptTestUtilities.java

Modified: cxf/trunk/rt/javascript/javascript-rt/src/main/resources/org/apache/cxf/javascript/cxf-utils.js
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/javascript/javascript-rt/src/main/resources/org/apache/cxf/javascript/cxf-utils.js?rev=1453958&r1=1453957&r2=1453958&view=diff
==============================================================================
--- cxf/trunk/rt/javascript/javascript-rt/src/main/resources/org/apache/cxf/javascript/cxf-utils.js
(original)
+++ cxf/trunk/rt/javascript/javascript-rt/src/main/resources/org/apache/cxf/javascript/cxf-utils.js
Thu Mar  7 17:01:53 2013
@@ -27,9 +27,12 @@ function cxf_apache_org_util_null_trace(
 
 function CxfApacheOrgUtil() {
 	// Set up tracing if there is a trace object.
-	if ("function" == typeof(org_apache_cxf_trace)) {
+	if ("object" == typeof(org_apache_cxf_trace)) {
 		this.trace = org_apache_cxf_trace.trace;
 		this.trace("Javascript tracing enabled.");
+	} else if ("function" == typeof(org_apache_cxf_trace)) {
+		this.trace = org_apache_cxf_trace;
+		this.trace("Javascript tracing enabled.");
 	} else {
 		this.trace = cxf_apache_org_util_null_trace;
 	}

Modified: cxf/trunk/rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/JavascriptTestUtilities.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/JavascriptTestUtilities.java?rev=1453958&r1=1453957&r2=1453958&view=diff
==============================================================================
--- cxf/trunk/rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/JavascriptTestUtilities.java
(original)
+++ cxf/trunk/rt/javascript/javascript-tests/src/test/java/org/apache/cxf/javascript/JavascriptTestUtilities.java
Thu Mar  7 17:01:53 2013
@@ -89,6 +89,10 @@ public class JavascriptTestUtilities ext
 
         public Trace() {
         }
+        //when acting as a function
+        public Trace(String msg) {
+            jsStaticFunction_trace(msg);
+        }
 
         @Override
         public String getClassName() {



Mime
View raw message