add some tests
[org.ibex.core.git] / tests / test.t
index 162aa96..30d7cc1 100644 (file)
@@ -1,17 +1,39 @@
 <ibex xmlns:ui="ibex://ui">
 <ibex xmlns:ui="ibex://ui">
-    <ui:box width="300" height="300" fill="red" axis="z">
+    <ui:box width="450" height="450" fill="red" axis="z">
         ibex.ui.frame = thisbox;
 
         ibex.ui.frame = thisbox;
 
-        <ui:box fill="blue" width="50" height="50" x="100" y="100" id="blue" axis="z"/>
+
+        <ui:box fill="blue" id="blue" shrink="true" axis="y">
+          <ui:box shrink="true" axis="x" fill="white">
+            <ui:box fill="green" width="25" height="25" id="green"/>
+            <ui:box fill="white" id="white" shrink="true" stroke="black">
+              <ui:box fill="black" stroke="black" text="hello"/>
+            </ui:box>
+            <ui:box fill="purple" height="25" width="25"  id="purple"/>
+          </ui:box>
+          <ui:box shrink="true" axis="x" fill="gray">
+            <ui:box fill="green" width="25" height="25" id="greenx"/>
+            <ui:box fill="white" id="whitex" shrink="true" stroke="black"/>
+            <ui:box fill="purple" height="25" width="25"  id="purplex"/>
+          </ui:box>
+        </ui:box>
 
         // this thread makes things spin.
         var rot = 0;
         ibex.thread = function(f) { while(true) {
              ibex.thread.sleep(100);
              $blue.transform = "rotate(" + rot + ")";
 
         // this thread makes things spin.
         var rot = 0;
         ibex.thread = function(f) { while(true) {
              ibex.thread.sleep(100);
              $blue.transform = "rotate(" + rot + ")";
-             $blue.x = 100;
-             $blue.y = 100;
+             $blue.x = 200;
+             $blue.y = 200;
+
+             $green.transform = "rotate(" + (rot) + ")";
+             //$white.transform = "rotate(" + (2 * rot) + ")";
+             $purple.transform = "rotate(" + (3 * rot) + ")";
+             $greenx.transform = "rotate(" + (-1 * rot) + ")";
+             //$whitex.transform = "rotate(" + (-2 * rot) + ")";
+             $purplex.transform = "rotate(" + (-3 * rot) + ")";
+
              rot += 5;
        } }
              rot += 5;
        } }
-    </ui:box>
+   </ui:box>
 </ibex>
 </ibex>