commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbe...@apache.org
Subject svn commit: r987169 - in /commons/sandbox/gsoc/2010/scxml-js/trunk: ./ test/rhino-jsc/arguments/ test/rhino-jsc/require-arguments/ test/rhino-jsc/require-arguments/foo/ test/rhino-jsc/require-arguments/foo/bar/ test/rhino-jsc/require-arguments/foo/bar/...
Date Thu, 19 Aug 2010 14:48:02 GMT
Author: jbeard
Date: Thu Aug 19 14:48:01 2010
New Revision: 987169

URL: http://svn.apache.org/viewvc?rev=987169&view=rev
Log:
Created Makefile, rather than using assorted shell scripts. Added new test to show that receiving
command-line arguments works in compiled code.

Added:
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/compile.sh   (contents,
props changed)
      - copied, changed from r987168, commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/compile.sh
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run-compiled.sh   (with
props)
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run.sh   (with props)
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/test.js   (with props)
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/Makefile   (with
props)
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/foo/
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/foo/bar/
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/foo/bar/bat/
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/foo/bar/bat/test.js
  (with props)
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/main.js   (with
props)
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/Makefile 
 (with props)
Removed:
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/compile.sh
    commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/run-compiled.sh
Modified:
    commons/sandbox/gsoc/2010/scxml-js/trunk/.gitignore

Modified: commons/sandbox/gsoc/2010/scxml-js/trunk/.gitignore
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/.gitignore?rev=987169&r1=987168&r2=987169&view=diff
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/.gitignore (original)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/.gitignore Thu Aug 19 14:48:01 2010
@@ -17,6 +17,5 @@ demo/hierarchical-layout/out.svg
 *.log
 demo/drawing-tool/lib/*
 *~
-test/rhino-jsc/hello-world/test.class
-test/rhino-jsc/require-hello-world/main-built.js
-test/rhino-jsc/require-hello-world/main_built.class
+test/rhino-jsc/*/*.class
+test/rhino-jsc/*/*-built.js

Copied: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/compile.sh (from
r987168, commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/compile.sh)
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/compile.sh?p2=commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/compile.sh&p1=commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/compile.sh&r1=987168&r2=987169&rev=987169&view=diff
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/compile.sh
(original)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/compile.sh Thu Aug 19
14:48:01 2010
@@ -1 +1 @@
-java -cp ../../../lib/java/js.jar org.mozilla.javascript.tools.jsc.Main main-built.js
+java -cp ../../../lib/java/js.jar org.mozilla.javascript.tools.jsc.Main test.js

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/compile.sh
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/compile.sh
------------------------------------------------------------------------------
    svn:executable = *

Added: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run-compiled.sh
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run-compiled.sh?rev=987169&view=auto
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run-compiled.sh (added)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run-compiled.sh Thu
Aug 19 14:48:01 2010
@@ -0,0 +1,3 @@
+#needs rhino on the classpath
+java -cp ../../../lib/java/js.jar:. test foo bar bat
+#should output foo,bar,bat

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run-compiled.sh
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run-compiled.sh
------------------------------------------------------------------------------
    svn:executable = *

Added: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run.sh
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run.sh?rev=987169&view=auto
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run.sh (added)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run.sh Thu Aug 19 14:48:01
2010
@@ -0,0 +1,2 @@
+rhino test.js foo bar bat
+#should output foo,bar,bat

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run.sh
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/run.sh
------------------------------------------------------------------------------
    svn:executable = *

Added: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/test.js
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/test.js?rev=987169&view=auto
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/test.js (added)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/test.js Thu Aug 19 14:48:01
2010
@@ -0,0 +1 @@
+print(arguments)

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/arguments/test.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/Makefile
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/Makefile?rev=987169&view=auto
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/Makefile (added)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/Makefile Thu
Aug 19 14:48:01 2010
@@ -0,0 +1,14 @@
+all: compile-with-closure compile-with-jsc run-compiled
+
+compile-with-closure:
+	../../../lib/js/requirejs/build/build.sh name=main out=main-built.js baseUrl=. includeRequire=true
+
+compile-with-jsc:
+	java -cp ../../../lib/java/js.jar org.mozilla.javascript.tools.jsc.Main main-built.js
+
+run-compiled:
+	java -cp ../../../lib/java/js.jar:. main_built foo bar bat
+	#should print foo,bar,bat
+
+clean:
+	rm main-built.js main_built.class

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/Makefile
------------------------------------------------------------------------------
    svn:eol-style = native

Added: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/foo/bar/bat/test.js
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/foo/bar/bat/test.js?rev=987169&view=auto
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/foo/bar/bat/test.js
(added)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/foo/bar/bat/test.js
Thu Aug 19 14:48:01 2010
@@ -0,0 +1,4 @@
+require.def("foo/bar/bat/test",
+{
+	go: function(cliArgs){print(cliArgs)}
+});

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/foo/bar/bat/test.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/main.js
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/main.js?rev=987169&view=auto
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/main.js (added)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/main.js Thu
Aug 19 14:48:01 2010
@@ -0,0 +1,6 @@
+(function(cliArgs){
+	require(["foo/bar/bat/test"],
+	function(testModule){
+		testModule.go(cliArgs);
+	});
+}).call(this,arguments);

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-arguments/main.js
------------------------------------------------------------------------------
    svn:eol-style = native

Added: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/Makefile
URL: http://svn.apache.org/viewvc/commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/Makefile?rev=987169&view=auto
==============================================================================
--- commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/Makefile (added)
+++ commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/Makefile Thu
Aug 19 14:48:01 2010
@@ -0,0 +1,14 @@
+all: compile-with-closure compile-with-jsc run-compiled
+
+compile-with-closure:
+	../../../lib/js/requirejs/build/build.sh name=main out=main-built.js baseUrl=. includeRequire=true
+
+compile-with-jsc:
+	java -cp ../../../lib/java/js.jar org.mozilla.javascript.tools.jsc.Main main-built.js
+
+run-compiled:
+	java -cp ../../../lib/java/js.jar:. main_built foo bar bat
+	#should print hello world!
+
+clean:
+	rm main-built.js main_built.class

Propchange: commons/sandbox/gsoc/2010/scxml-js/trunk/test/rhino-jsc/require-hello-world/Makefile
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message