flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aha...@apache.org
Subject [2/3] git commit: [flex-falcon] [refs/heads/develop] - add qname test
Date Fri, 13 Nov 2015 05:34:13 GMT
add qname test


Project: http://git-wip-us.apache.org/repos/asf/flex-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-falcon/commit/0a9e4a90
Tree: http://git-wip-us.apache.org/repos/asf/flex-falcon/tree/0a9e4a90
Diff: http://git-wip-us.apache.org/repos/asf/flex-falcon/diff/0a9e4a90

Branch: refs/heads/develop
Commit: 0a9e4a9060dae928f08b31f6945a56d22857935e
Parents: cc85f50
Author: Alex Harui <aharui@apache.org>
Authored: Thu Nov 12 20:10:05 2015 -0800
Committer: Alex Harui <aharui@apache.org>
Committed: Thu Nov 12 21:33:33 2015 -0800

----------------------------------------------------------------------
 .../feature-tests/as/ASNamespaceTests.java      | 22 ++++++++++++++++++++
 1 file changed, 22 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-falcon/blob/0a9e4a90/compiler.tests/feature-tests/as/ASNamespaceTests.java
----------------------------------------------------------------------
diff --git a/compiler.tests/feature-tests/as/ASNamespaceTests.java b/compiler.tests/feature-tests/as/ASNamespaceTests.java
index 42b5f80..5d970f7 100644
--- a/compiler.tests/feature-tests/as/ASNamespaceTests.java
+++ b/compiler.tests/feature-tests/as/ASNamespaceTests.java
@@ -68,4 +68,26 @@ public class ASNamespaceTests extends ASFeatureTestsBase
         compileAndRun(source);
     }
 
+    @Test
+    public void ASNamespace_QNameDefinition()
+    {
+    	// all tests can assume that flash.display.Sprite
+    	// flash.system.System and flash.events.Event have been imported
+        String[] imports = new String[]
+        {
+            "import flash.utils.getQualifiedClassName;",
+            "import flash.utils.flash_proxy;",
+        };
+        String[] declarations = new String[]
+        {
+	       	"flash_proxy var foo:Event = new Event('foo');",
+        };
+        String[] testCode = new String[]
+        {
+        	"var ns:Namespace = new Namespace('baz', 'bar');",
+        	"var qname:QName = new QName(ns, 'foo');",
+        };
+        String source = getAS(imports, declarations, testCode, new String[0]);
+        compileAndRun(source);
+    }
 }


Mime
View raw message