[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] /srv/bzr/gnash/trunk r10961: Updated test cases and fixed
From: |
Bob Naugle |
Subject: |
[Gnash-commit] /srv/bzr/gnash/trunk r10961: Updated test cases and fixed geom/Transform_as.hx |
Date: |
Mon, 01 Jun 2009 16:01:49 -0600 |
User-agent: |
Bazaar (1.13.1) |
------------------------------------------------------------
revno: 10961
committer: Bob Naugle <address@hidden>
branch nick: trunk
timestamp: Mon 2009-06-01 16:01:49 -0600
message:
Updated test cases and fixed geom/Transform_as.hx
modified:
testsuite/as3/classes.all/display/BitmapDataChannel_as.hx
testsuite/as3/classes.all/display/BlendMode_as.hx
testsuite/as3/classes.all/display/CapsStyle_as.hx
testsuite/as3/classes.all/display/DisplayObjectContainer_as.hx
testsuite/as3/classes.all/display/Graphics_as.hx
testsuite/as3/classes.all/display/InteractiveObject_as.hx
testsuite/as3/classes.all/display/InterpolationMethod_as.hx
testsuite/as3/classes.all/display/SWFVersion_as.hx
testsuite/as3/classes.all/geom/Transform_as.hx
=== modified file 'testsuite/as3/classes.all/display/BitmapDataChannel_as.hx'
--- a/testsuite/as3/classes.all/display/BitmapDataChannel_as.hx 2009-05-21
00:17:43 +0000
+++ b/testsuite/as3/classes.all/display/BitmapDataChannel_as.hx 2009-06-01
22:01:49 +0000
@@ -26,9 +26,6 @@
#if flash9
import flash.display.BitmapDataChannel;
import flash.display.MovieClip;
-#else
-import flash.BitmapDataChannel;
-import flash.MovieClip;
#end
import flash.Lib;
import Type;
@@ -39,26 +36,27 @@
// Class must be named with the _as suffix, as that's the same name as the
file.
class BitmapDataChannel_as {
static function main() {
+#if flash9
// Make sure we actually get a valid class
- if (BitmapDataChannel.ALPHA != null) {
+ if (BitmapDataChannel.ALPHA == 8) {
DejaGnu.pass("BitmapDataChannel.ALPHA class exists");
} else {
DejaGnu.fail("BitmapDataChannel.ALPHA lass doesn't exist");
}
- if (BitmapDataChannel.RED != null) {
+ if (BitmapDataChannel.RED == 4) {
DejaGnu.pass("BitmapDataChannel.RED class exists");
} else {
DejaGnu.fail("BitmapDataChannel.RED lass doesn't exist");
}
- if (BitmapDataChannel.BLUE != null) {
+ if (BitmapDataChannel.BLUE == 2) {
DejaGnu.pass("BitmapDataChannel.BLUE class exists");
} else {
DejaGnu.fail("BitmapDataChannel.BLUE lass doesn't exist");
}
- if (BitmapDataChannel.GREEN != null) {
+ if (BitmapDataChannel.GREEN == 1) {
DejaGnu.pass("BitmapDataChannel.GREEN class exists");
} else {
DejaGnu.fail("BitmapDataChannel.GREEN lass doesn't exist");
@@ -70,6 +68,9 @@
// Call this after finishing all tests. It prints out the totals.
DejaGnu.done();
+#else
+ DejaGnu.note("This class (BitmapDataChannel) is only available in
flash9");
+#end
}
}
=== modified file 'testsuite/as3/classes.all/display/BlendMode_as.hx'
--- a/testsuite/as3/classes.all/display/BlendMode_as.hx 2009-05-21 00:17:43
+0000
+++ b/testsuite/as3/classes.all/display/BlendMode_as.hx 2009-06-01 22:01:49
+0000
@@ -1,6 +1,6 @@
// BlendMode_as.hx: ActionScript 3 "BlendMode" class, for Gnash.
//
-// Generated by gen-as3.sh on: 20090514 by "rob". Remove this
+// Generated on: 20090601 by "bnaugle". Remove this
// after any hand editing loosing changes.
//
// Copyright (C) 2009 Free Software Foundation, Inc.
@@ -26,9 +26,6 @@
#if flash9
import flash.display.BlendMode;
import flash.display.MovieClip;
-#else
-import flash.BlendMode;
-import flash.MovieClip;
#end
import flash.Lib;
import Type;
@@ -39,88 +36,229 @@
// Class must be named with the _as suffix, as that's the same name as the
file.
class BlendMode_as {
static function main() {
+#if flash9
// Make sure we actually get a valid class
if (BlendMode.ADD != null) {
DejaGnu.pass("BlendMode.ADD class exists");
+ if (Std.is(BlendMode.ADD, String)) {
+ DejaGnu.pass("BlendMode.ADD is a String");
+ if (Std.string(BlendMode.ADD) == "add") {
+ DejaGnu.pass("BlendMode.ADD is the correct string
(add)");
+ } else {
+ DejaGnu.fail("BlendMode.ADD is not the correct string
(Should be add, but is "+BlendMode.ADD+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.ADD is not a string. Instead, it is a
"+Type.typeof(BlendMode.ADD));
+ }
} else {
DejaGnu.fail("BlendMode.ADD class doesn't exist");
}
if (BlendMode.ALPHA != null) {
DejaGnu.pass("BlendMode.ALPHA class exists");
+ if (Std.is(BlendMode.ALPHA, String)) {
+ DejaGnu.pass("BlendMode.ALPHA is a String");
+ if (Std.string(BlendMode.ALPHA) == "alpha") {
+ DejaGnu.pass("BlendMode.ALPHA is the correct string
(alpha)");
+ } else {
+ DejaGnu.fail("BlendMode.ALPHA is not the correct string
(Should be alpha, but is "+BlendMode.ALPHA+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.ALPHA is not a string. Instead, it is a
"+Type.typeof(BlendMode.ALPHA));
+ }
} else {
DejaGnu.fail("BlendMode.ALPHA class doesn't exist");
}
if (BlendMode.DARKEN != null) {
DejaGnu.pass("BlendMode.DARKEN class exists");
+ if (Std.is(BlendMode.DARKEN, String)) {
+ DejaGnu.pass("BlendMode.DARKEN is a String");
+ if (Std.string(BlendMode.DARKEN) == "darken") {
+ DejaGnu.pass("BlendMode.DARKEN is the correct string
(darken)");
+ } else {
+ DejaGnu.fail("BlendMode.DARKEN is not the correct
string (Should be darken, but is "+BlendMode.DARKEN+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.DARKEN is not a string. Instead, it is
a "+Type.typeof(BlendMode.DARKEN));
+ }
} else {
DejaGnu.fail("BlendMode.DARKEN class doesn't exist");
}
if (BlendMode.DIFFERENCE != null) {
DejaGnu.pass("BlendMode.DIFFERENCE class exists");
+ if (Std.is(BlendMode.DIFFERENCE, String)) {
+ DejaGnu.pass("BlendMode.DIFFERENCE is a String");
+ if (Std.string(BlendMode.DIFFERENCE) == "difference") {
+ DejaGnu.pass("BlendMode.DIFFERENCE is the correct
string (difference)");
+ } else {
+ DejaGnu.fail("BlendMode.DIFFERENCE is not the correct
string (Should be difference, but is "+BlendMode.DIFFERENCE+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.DIFFERENCE is not a string. Instead, it
is a "+Type.typeof(BlendMode.DIFFERENCE));
+ }
} else {
DejaGnu.fail("BlendMode.DIFFERENCE class doesn't exist");
}
if (BlendMode.ERASE != null) {
DejaGnu.pass("BlendMode.ERASE class exists");
+ if (Std.is(BlendMode.ERASE, String)) {
+ DejaGnu.pass("BlendMode.ERASE is a String");
+ if (Std.string(BlendMode.ERASE) == "erase") {
+ DejaGnu.pass("BlendMode.ERASE is the correct string
(erase)");
+ } else {
+ DejaGnu.fail("BlendMode.ERASE is not the correct string
(Should be erase, but is "+BlendMode.ERASE+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.ERASE is not a string. Instead, it is a
"+Type.typeof(BlendMode.ERASE));
+ }
} else {
DejaGnu.fail("BlendMode.ERASE class doesn't exist");
}
if (BlendMode.HARDLIGHT != null) {
DejaGnu.pass("BlendMode.HARDLIGHT class exists");
+ if (Std.is(BlendMode.HARDLIGHT, String)) {
+ DejaGnu.pass("BlendMode.HARDLIGHT is a String");
+ if (Std.string(BlendMode.HARDLIGHT) == "hardlight") {
+ DejaGnu.pass("BlendMode.HARDLIGHT is the correct string
(hardlight)");
+ } else {
+ DejaGnu.fail("BlendMode.HARDLIGHT is not the correct
string (Should be hardlight, but is "+BlendMode.HARDLIGHT+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.HARDLIGHT is not a string. Instead, it
is a "+Type.typeof(BlendMode.HARDLIGHT));
+ }
} else {
DejaGnu.fail("BlendMode.HARDLIGHT class doesn't exist");
}
if (BlendMode.INVERT != null) {
DejaGnu.pass("BlendMode.INVERT class exists");
+ if (Std.is(BlendMode.INVERT, String)) {
+ DejaGnu.pass("BlendMode.INVERT is a String");
+ if (Std.string(BlendMode.INVERT) == "invert") {
+ DejaGnu.pass("BlendMode.INVERT is the correct string
(invert)");
+ } else {
+ DejaGnu.fail("BlendMode.HARDLIGHT is not the correct
string (Should be invert, but is "+BlendMode.INVERT+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.INVERT is not a string. Instead, it is
a "+Type.typeof(BlendMode.INVERT));
+ }
} else {
DejaGnu.fail("BlendMode.INVERT class doesn't exist");
}
if (BlendMode.LAYER != null) {
DejaGnu.pass("BlendMode.LAYER class exists");
+ if (Std.is(BlendMode.INVERT, String)) {
+ DejaGnu.pass("BlendMode.LAYER is a String");
+ if (Std.string(BlendMode.LAYER) == "layer") {
+ DejaGnu.pass("BlendMode.LAYER is the correct string
(layer)");
+ } else {
+ DejaGnu.fail("BlendMode.LAYER is not the correct string
(Should be layer, but is "+BlendMode.LAYER+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.LAYER is not a string. Instead, it is a
"+Type.typeof(BlendMode.LAYER));
+ }
} else {
DejaGnu.fail("BlendMode.LAYER class doesn't exist");
}
if (BlendMode.LIGHTEN != null) {
DejaGnu.pass("BlendMode.LIGHTEN class exists");
+ if (Std.is(BlendMode.LIGHTEN, String)) {
+ DejaGnu.pass("BlendMode.LIGHTEN is a String");
+ if (Std.string(BlendMode.LIGHTEN) == "lighten") {
+ DejaGnu.pass("BlendMode.LIGHTEN is the correct string
(lighten)");
+ } else {
+ DejaGnu.fail("BlendMode.LIGHTEN is not the correct
string (Should be lighten, but is "+BlendMode.LIGHTEN+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.LIGHTEN is not a string. Instead, it is
a "+Type.typeof(BlendMode.LIGHTEN));
+ }
} else {
DejaGnu.fail("BlendMode.LIGHTEN class doesn't exist");
}
if (BlendMode.MULTIPLY != null) {
DejaGnu.pass("BlendMode.MULTIPLY class exists");
+ if (Std.is(BlendMode.MULTIPLY, String)) {
+ DejaGnu.pass("BlendMode.MULTIPLY is a String");
+ if (Std.string(BlendMode.MULTIPLY) == "multiply") {
+ DejaGnu.pass("BlendMode.MULTIPLY is the correct string
(multiply)");
+ } else {
+ DejaGnu.fail("BlendMode.MULTIPLY is not the correct
string (Should be multiply, but is "+BlendMode.MULTIPLY+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.MULTIPLY is not a string. Instead, it
is a "+Type.typeof(BlendMode.MULTIPLY));
+ }
} else {
DejaGnu.fail("BlendMode.MULTIPLY class doesn't exist");
}
if (BlendMode.NORMAL != null) {
DejaGnu.pass("BlendMode.NORMAL class exists");
+ if (Std.is(BlendMode.NORMAL, String)) {
+ DejaGnu.pass("BlendMode.NORMAL is a String");
+ if (Std.string(BlendMode.NORMAL) == "normal") {
+ DejaGnu.pass("BlendMode.NORMAL is the correct string
(normal)");
+ } else {
+ DejaGnu.fail("BlendMode.NORMAL is not the correct
string (Should be normal, but is "+BlendMode.NORMAL+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.NORMAL is not a string. Instead, it is
a "+Type.typeof(BlendMode.NORMAL));
+ }
} else {
DejaGnu.fail("BlendMode.NORMAL class doesn't exist");
}
if (BlendMode.OVERLAY != null) {
DejaGnu.pass("BlendMode.OVERLAY class exists");
+ if (Std.is(BlendMode.OVERLAY, String)) {
+ DejaGnu.pass("BlendMode.OVERLAY is a String");
+ if (Std.string(BlendMode.OVERLAY) == "overlay") {
+ DejaGnu.pass("BlendMode.OVERLAY is the correct string
(overlay)");
+ } else {
+ DejaGnu.fail("BlendMode.OVERLAY is not the correct
string (Should be overlay, but is "+BlendMode.OVERLAY+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.OVERLAY is not a string. Instead, it is
a "+Type.typeof(BlendMode.OVERLAY));
+ }
} else {
DejaGnu.fail("BlendMode.OVERLAY class doesn't exist");
}
if (BlendMode.SCREEN != null) {
DejaGnu.pass("BlendMode.SCREEN class exists");
+ if (Std.is(BlendMode.SCREEN, String)) {
+ DejaGnu.pass("BlendMode.SCREEN is a String");
+ if (Std.string(BlendMode.SCREEN) == "screen") {
+ DejaGnu.pass("BlendMode.SCREEN is the correct string
(screen)");
+ } else {
+ DejaGnu.fail("BlendMode.SCREEN is not the correct
string (Should be screen, but is "+BlendMode.SCREEN+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.SCREEN is not a string. Instead, it is
a "+Type.typeof(BlendMode.SCREEN));
+ }
} else {
DejaGnu.fail("BlendMode.SCREEN class doesn't exist");
}
if (BlendMode.SUBTRACT != null) {
DejaGnu.pass("BlendMode.SUBTRACT class exists");
+ if (Std.is(BlendMode.SUBTRACT, String)) {
+ DejaGnu.pass("BlendMode.SUBTRACT is a String");
+ if (Std.string(BlendMode.SUBTRACT) == "subtract") {
+ DejaGnu.pass("BlendMode.SUBTRACT is the correct string
(subtract)");
+ } else {
+ DejaGnu.fail("BlendMode.SUBTRACT is not the correct
string (Should be subtract, but is "+BlendMode.SUBTRACT+")");
+ }
+ } else {
+ DejaGnu.fail("BlendMode.SUBTRACT is not a string. Instead, it
is a "+Type.typeof(BlendMode.SUBTRACT));
+ }
} else {
DejaGnu.fail("BlendMode.SUBTRACT class doesn't exist");
}
@@ -131,6 +269,9 @@
// Call this after finishing all tests. It prints out the totals.
DejaGnu.done();
+#else
+ DejaGnu.note("This class (BlendMode) is only available in flash9");
+#end
}
}
=== modified file 'testsuite/as3/classes.all/display/CapsStyle_as.hx'
--- a/testsuite/as3/classes.all/display/CapsStyle_as.hx 2009-05-21 00:17:43
+0000
+++ b/testsuite/as3/classes.all/display/CapsStyle_as.hx 2009-06-01 22:01:49
+0000
@@ -1,6 +1,6 @@
// CapsStyle_as.hx: ActionScript 3 "CapsStyle" class, for Gnash.
//
-// Generated by gen-as3.sh on: 20090514 by "rob". Remove this
+// Generated on: 20090601 by "bnaugle". Remove this
// after any hand editing loosing changes.
//
// Copyright (C) 2009 Free Software Foundation, Inc.
@@ -26,9 +26,6 @@
#if flash9
import flash.display.CapsStyle;
import flash.display.MovieClip;
-#else
-import flash.CapsStyle;
-import flash.MovieClip;
#end
import flash.Lib;
import Type;
@@ -39,21 +36,51 @@
// Class must be named with the _as suffix, as that's the same name as the
file.
class CapsStyle_as {
static function main() {
-
+#if flash9
if (CapsStyle.NONE != null) {
DejaGnu.pass("CapsStyle.NONE constant exists");
+ if (Std.is(CapsStyle.NONE, String)) {
+ DejaGnu.pass("CapsStyle.NONE is a String");
+ if (Std.string(CapsStyle.NONE) == "none") {
+ DejaGnu.pass("CapsStyle.NONE is the correct string
(none)");
+ } else {
+ DejaGnu.fail("CapsStyle.NONE is not the correct string
(Should be none, but is "+CapsStyle.NONE+")");
+ }
+ } else {
+ DejaGnu.fail("CapsStyle.NONE is not a string. Instead, it is a
"+Type.typeof(CapsStyle.NONE));
+ }
} else {
DejaGnu.fail("CapsStyle.NONE constant doesn't exist");
}
if (CapsStyle.ROUND != null) {
DejaGnu.pass("CapsStyle.ROUND constant exists");
+ if (Std.is(CapsStyle.ROUND, String)) {
+ DejaGnu.pass("CapsStyle.ROUND is a String");
+ if (Std.string(CapsStyle.ROUND) == "round") {
+ DejaGnu.pass("CapsStyle.ROUND is the correct string
(round)");
+ } else {
+ DejaGnu.fail("CapsStyle.ROUND is not the correct string
(Should be round, but is "+CapsStyle.ROUND+")");
+ }
+ } else {
+ DejaGnu.fail("CapsStyle.ROUND is not a string. Instead, it is a
"+Type.typeof(CapsStyle.ROUND));
+ }
} else {
DejaGnu.fail("CapsStyle.ROUND constant doesn't exist");
}
if (CapsStyle.SQUARE != null) {
DejaGnu.pass("CapsStyle.SQUARE constant exists");
+ if (Std.is(CapsStyle.SQUARE, String)) {
+ DejaGnu.pass("CapsStyle.SQUARE is a String");
+ if (Std.string(CapsStyle.SQUARE) == "square") {
+ DejaGnu.pass("CapsStyle.SQUARE is the correct string
(square)");
+ } else {
+ DejaGnu.fail("CapsStyle.SQUARE is not the correct
string (Should be square, but is "+CapsStyle.SQUARE+")");
+ }
+ } else {
+ DejaGnu.fail("CapsStyle.SQUARE is not a string. Instead, it is
a "+Type.typeof(CapsStyle.SQUARE));
+ }
} else {
DejaGnu.fail("CapsStyle.SQUARE constant doesn't exist");
}
@@ -64,6 +91,9 @@
// Call this after finishing all tests. It prints out the totals.
DejaGnu.done();
+#else
+ DejaGnu.note("This class (CapsStyle) is only available in flash9");
+#end
}
}
=== modified file
'testsuite/as3/classes.all/display/DisplayObjectContainer_as.hx'
--- a/testsuite/as3/classes.all/display/DisplayObjectContainer_as.hx
2009-05-21 00:17:43 +0000
+++ b/testsuite/as3/classes.all/display/DisplayObjectContainer_as.hx
2009-06-01 22:01:49 +0000
@@ -25,13 +25,10 @@
#if flash9
import flash.display.DisplayObjectContainer;
+import flash.display.Sprite;
import flash.geom.Point;
import flash.text.TextSnapshot;
import flash.display.MovieClip;
-#else
-import flash.DisplayObjectContainer;
-import flash.TextSnapshot;
-import flash.MovieClip;
#end
import flash.Lib;
import Type;
@@ -42,10 +39,11 @@
// Class must be named with the _as suffix, as that's the same name as the
file.
class DisplayObjectContainer_as {
static function main() {
- var x1:DisplayObjectContainer = new DisplayObjectContainer();
+#if flash9
+ var x1:DisplayObjectContainer = new Sprite();
// Make sure we actually get a valid class
- if (x1 != null) {
+ if (Std.is(x1, DisplayObjectContainer)) {
DejaGnu.pass("DisplayObjectContainer class exists");
} else {
DejaGnu.fail("DisplayObjectContainer lass doesn't exist");
@@ -53,98 +51,92 @@
// Tests to see if all the properties exist. All these do is test for
// existance of a property, and don't test the functionality at all. This
// is primarily useful only to test completeness of the API implementation.
- if (x1.mouseChildren == false) {
+ if (Std.is(x1.mouseChildren, Bool)) {
DejaGnu.pass("DisplayObjectContainer::mouseChildren property
exists");
} else {
DejaGnu.fail("DisplayObjectContainer::mouseChildren property
doesn't exist");
}
- if (x1.numChildren == 0) {
+ if (Std.is(x1.numChildren, Int)) {
DejaGnu.pass("DisplayObjectContainer::numChildren property exists");
} else {
DejaGnu.fail("DisplayObjectContainer::numChildren property doesn't
exist");
}
- if (x1.tabChildren == false) {
+ if (Std.is(x1.tabChildren, Bool)) {
DejaGnu.pass("DisplayObjectContainer::tabChildren property exists");
} else {
DejaGnu.fail("DisplayObjectContainer::tabChildren property doesn't
exist");
}
-// if (x1.textSnapshot == textSnapshot) {
-// DejaGnu.pass("DisplayObjectContainer::textSnapshot property
exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::textSnapshot property doesn't
exist");
-// }
+ if (Std.is(x1.textSnapshot, TextSnapshot)) {
+ DejaGnu.pass("DisplayObjectContainer::textSnapshot property
exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::textSnapshot property doesn't
exist");
+ }
// Tests to see if all the methods exist. All these do is test for
// existance of a method, and don't test the functionality at all. This
// is primarily useful only to test completeness of the API implementation.
-// if (x1.DisplayObjectContainer == DisplayObjectContainer) {
-// DejaGnu.pass("DisplayObjectContainer::DisplayObjectContainer()
method exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::DisplayObjectContainer()
method doesn't exist");
-// }
-// if (x1.addChild == DisplayObject) {
-// DejaGnu.pass("DisplayObjectContainer::addChild() method exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::addChild() method doesn't
exist");
-// }
-// if (x1.addChildAt == DisplayObject) {
-// DejaGnu.pass("DisplayObjectContainer::addChildAt() method exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::addChildAt() method doesn't
exist");
-// }
+ if (Type.typeof(x1.addChild) == ValueType.TFunction) {
+ DejaGnu.pass("DisplayObjectContainer::addChild() method exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::addChild() method doesn't
exist");
+ }
+ if (Type.typeof(x1.addChildAt) == ValueType.TFunction) {
+ DejaGnu.pass("DisplayObjectContainer::addChildAt() method exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::addChildAt() method doesn't
exist");
+ }
// FIXME: this needs to be a point
-// if (x1.areInaccessibleObjectsUnderPoint == false) {
-//
DejaGnu.pass("DisplayObjectContainer::areInaccessibleObjectsUnderPoint() method
exists");
-// } else {
-//
DejaGnu.fail("DisplayObjectContainer::areInaccessibleObjectsUnderPoint() method
doesn't exist");
-// }
-// if (x1.contains == false) {
-// DejaGnu.pass("DisplayObjectContainer::contains() method exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::contains() method doesn't
exist");
-// }
-
-// if (x1.getChildAt == DisplayObject) {
-// DejaGnu.pass("DisplayObjectContainer::getChildAt() method exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::getChildAt() method doesn't
exist");
-// }
-// if (x1.getChildByName == DisplayObject) {
-// DejaGnu.pass("DisplayObjectContainer::getChildByName() method
exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::getChildByName() method
doesn't exist");
-// }
-// if (x1.getChildIndex == 0) {
-// DejaGnu.pass("DisplayObjectContainer::getChildIndex() method
exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::getChildIndex() method
doesn't exist");
-// }
-// if (x1.getObjectsUnderPoint == 0) {
-// DejaGnu.pass("DisplayObjectContainer::getObjectsUnderPoint() method
exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::getObjectsUnderPoint() method
doesn't exist");
-// }
-// if (x1.removeChild == DisplayObject) {
-// DejaGnu.pass("DisplayObjectContainer::removeChild() method exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::removeChild() method doesn't
exist");
-// }
-// if (x1.removeChildAt == DisplayObject) {
-// DejaGnu.pass("DisplayObjectContainer::removeChildAt() method
exists");
-// } else {
-// DejaGnu.fail("DisplayObjectContainer::removeChildAt() method
doesn't exist");
-// }
- if (x1.setChildIndex == null) {
+ if (Type.typeof(x1.areInaccessibleObjectsUnderPoint) ==
ValueType.TFunction) {
+
DejaGnu.pass("DisplayObjectContainer::areInaccessibleObjectsUnderPoint() method
exists");
+ } else {
+
DejaGnu.fail("DisplayObjectContainer::areInaccessibleObjectsUnderPoint() method
doesn't exist");
+ }
+ if (Type.typeof(x1.contains) == ValueType.TFunction) {
+ DejaGnu.pass("DisplayObjectContainer::contains() method
exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::contains() method doesn't
exist");
+ }
+ if (Type.typeof(x1.getChildAt) == ValueType.TFunction) {
+ DejaGnu.pass("DisplayObjectContainer::getChildAt() method exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::getChildAt() method doesn't
exist");
+ }
+ if (Type.typeof(x1.getChildByName) == ValueType.TFunction) {
+ DejaGnu.pass("DisplayObjectContainer::getChildByName() method
exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::getChildByName() method
doesn't exist");
+ }
+ if (Type.typeof(x1.getChildIndex) == ValueType.TFunction) {
+ DejaGnu.pass("DisplayObjectContainer::getChildIndex() method
exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::getChildIndex() method
doesn't exist");
+ }
+ if (Type.typeof(x1.getObjectsUnderPoint) == ValueType.TFunction) {
+ DejaGnu.pass("DisplayObjectContainer::getObjectsUnderPoint() method
exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::getObjectsUnderPoint() method
doesn't exist");
+ }
+ if (Type.typeof(x1.removeChild) == ValueType.TFunction) {
+ DejaGnu.pass("DisplayObjectContainer::removeChild() method exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::removeChild() method doesn't
exist");
+ }
+ if (Type.typeof(x1.removeChildAt) == ValueType.TFunction) {
+ DejaGnu.pass("DisplayObjectContainer::removeChildAt() method
exists");
+ } else {
+ DejaGnu.fail("DisplayObjectContainer::removeChildAt() method
doesn't exist");
+ }
+ if (Type.typeof(x1.setChildIndex) == ValueType.TFunction) {
DejaGnu.pass("DisplayObjectContainer::setChildIndex() method
exists");
} else {
DejaGnu.fail("DisplayObjectContainer::setChildIndex() method
doesn't exist");
}
- if (x1.swapChildren == null) {
+ if (Type.typeof(x1.swapChildren) == ValueType.TFunction) {
DejaGnu.pass("DisplayObjectContainer::swapChildren() method
exists");
} else {
DejaGnu.fail("DisplayObjectContainer::swapChildren() method doesn't
exist");
}
- if (x1.swapChildrenAt == null) {
+ if (Type.typeof(x1.swapChildrenAt) == ValueType.TFunction) {
DejaGnu.pass("DisplayObjectContainer::swapChildrenAt() method
exists");
} else {
DejaGnu.fail("DisplayObjectContainer::swapChildrenAt() method
doesn't exist");
@@ -152,6 +144,9 @@
// Call this after finishing all tests. It prints out the totals.
DejaGnu.done();
+#else
+ DejaGnu.note("This class (DisplayObjectContainer) is only available in
flash9");
+#end
}
}
=== modified file 'testsuite/as3/classes.all/display/Graphics_as.hx'
--- a/testsuite/as3/classes.all/display/Graphics_as.hx 2009-05-21 00:17:43
+0000
+++ b/testsuite/as3/classes.all/display/Graphics_as.hx 2009-06-01 22:01:49
+0000
@@ -1,6 +1,6 @@
// Graphics_as.hx: ActionScript 3 "Graphics" class, for Gnash.
//
-// Generated by gen-as3.sh on: 20090514 by "rob". Remove this
+// Generated on: 20090601 by "bnaugle". Remove this
// after any hand editing loosing changes.
//
// Copyright (C) 2009 Free Software Foundation, Inc.
@@ -26,12 +26,11 @@
#if flash9
import flash.display.Graphics;
import flash.display.MovieClip;
-#else
-import flash.Graphics;
-import flash.MovieClip;
+import flash.display.Shape;
#end
import flash.Lib;
import Type;
+import Std;
// import our testing API
import DejaGnu;
@@ -39,10 +38,12 @@
// Class must be named with the _as suffix, as that's the same name as the
file.
class Graphics_as {
static function main() {
- var x1:Graphics = new Graphics();
+#if flash9
+ var s1:Shape = new Shape();
+ var x1:Graphics = s1.graphics; //Graphics property of DisplayObject is
Graphics object
// Make sure we actually get a valid class
- if (x1 != null) {
+ if (Std.is(x1, Graphics)) {
DejaGnu.pass("Graphics class exists");
} else {
DejaGnu.fail("Graphics lass doesn't exist");
@@ -52,8 +53,87 @@
// existance of a method, and don't test the functionality at all. This
// is primarily useful only to test completeness of the API implementation.
+ if (Type.typeof(x1.beginBitmapFill) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::beginBitmapFill method exists");
+ } else {
+ DejaGnu.fail("Graphics::beginBitmapFill method doesn't exist");
+ }
+ if (Type.typeof(x1.beginFill) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::beginFill method exists");
+ } else {
+ DejaGnu.fail("Graphics::beginFill method doesn't exist");
+ }
+ if (Type.typeof(x1.beginGradientFill) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::beginGradientFill method exists");
+ } else {
+ DejaGnu.fail("Graphics::beginGradientFill method doesn't
exist");
+ }
+ if (Type.typeof(x1.clear) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::clear method exists");
+ } else {
+ DejaGnu.fail("Graphics::clear method doesn't exist");
+ }
+ if (Type.typeof(x1.curveTo) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::curveTo method exists");
+ } else {
+ DejaGnu.fail("Graphics::curveTo method doesn't exist");
+ }
+ if (Type.typeof(x1.drawCircle) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::drawCircle method exists");
+ } else {
+ DejaGnu.fail("Graphics::drawCircle method doesn't exist");
+ }
+ if (Type.typeof(x1.drawEllipse) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::drawEllipse method exists");
+ } else {
+ DejaGnu.fail("Graphics::drawEllipse method doesn't exist");
+ }
+ if (Type.typeof(x1.drawRect) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::drawRect method exists");
+ } else {
+ DejaGnu.fail("Graphics::drawRect method doesn't exist");
+ }
+ if (Type.typeof(x1.drawRoundRect) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::drawRoundRect method exists");
+ } else {
+ DejaGnu.fail("Graphics::drawRoundRect method doesn't exist");
+ }
+ if (Type.typeof(x1.drawRoundRectComplex) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::drawRoundRectComplex method exists");
+ } else {
+ DejaGnu.fail("Graphics::drawRoundRectComplex method doesn't
exist");
+ }
+ if (Type.typeof(x1.endFill) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::endFill method exists");
+ } else {
+ DejaGnu.fail("Graphics::endFill method doesn't exist");
+ }
+ if (Type.typeof(x1.lineGradientStyle) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::lineGradientStyle method exists");
+ } else {
+ DejaGnu.fail("Graphics::lineGradientStyle method doesn't
exist");
+ }
+ if (Type.typeof(x1.lineStyle) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::lineStyle method exists");
+ } else {
+ DejaGnu.fail("Graphics::lineStyle method doesn't exist");
+ }
+ if (Type.typeof(x1.lineTo) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::lineTo method exists");
+ } else {
+ DejaGnu.fail("Graphics::lineTo method doesn't exist");
+ }
+ if (Type.typeof(x1.moveTo) == ValueType.TFunction) {
+ DejaGnu.pass("Graphics::moveTo method exists");
+ } else {
+ DejaGnu.fail("Graphics::moveTo method doesn't exist");
+ }
+
// Call this after finishing all tests. It prints out the totals.
DejaGnu.done();
+#else
+ DejaGnu.note("This class (Graphics) only exists in flash9");
+#end
}
}
=== modified file 'testsuite/as3/classes.all/display/InteractiveObject_as.hx'
--- a/testsuite/as3/classes.all/display/InteractiveObject_as.hx 2009-05-21
00:17:43 +0000
+++ b/testsuite/as3/classes.all/display/InteractiveObject_as.hx 2009-06-01
22:01:49 +0000
@@ -1,6 +1,6 @@
// InteractiveObject_as.hx: ActionScript 3 "InteractiveObject" class, for
Gnash.
//
-// Generated by gen-as3.sh on: 20090514 by "rob". Remove this
+// Generated on: 20090601 by "bnaugle". Remove this
// after any hand editing loosing changes.
//
// Copyright (C) 2009 Free Software Foundation, Inc.
@@ -24,11 +24,11 @@
// DejaGnu.hx header file for the testing framework support.
#if flash9
+import flash.accessibility.AccessibilityImplementation;
import flash.display.InteractiveObject;
import flash.display.MovieClip;
-#else
-import flash.InteractiveObject;
-import flash.MovieClip;
+import flash.display.SimpleButton;
+import flash.ui.ContextMenu;
#end
import flash.Lib;
import Type;
@@ -39,10 +39,11 @@
// Class must be named with the _as suffix, as that's the same name as the
file.
class InteractiveObject_as {
static function main() {
- var x1:InteractiveObject = new InteractiveObject();
+#if flash9
+ var x1:InteractiveObject = new SimpleButton();
// Make sure we actually get a valid class
- if (x1 != null) {
+ if (Std.is(x1, InteractiveObject)) {
DejaGnu.pass("InteractiveObject class exists");
} else {
DejaGnu.fail("InteractiveObject lass doesn't exist");
@@ -50,32 +51,42 @@
// Tests to see if all the properties exist. All these do is test for
// existance of a property, and don't test the functionality at all. This
// is primarily useful only to test completeness of the API implementation.
-// if (x1.contextMenu == NativeMenu) {
-// DejaGnu.pass("InteractiveObject::contextMenu property exists");
-// } else {
-// DejaGnu.fail("InteractiveObject::contextMenu property doesn't
exist");
-// }
- if (x1.doubleClickEnabled == false) {
+//FIXME: This property, and the AccessibilityImplementation class, only exist
in haXe
+ var a1:AccessibilityImplementation = new AccessibilityImplementation();
+ x1.accessibilityImplementation = a1;
+ if (Std.is(x1.accessibilityImplementation,
AccessibilityImplementation)) {
+ DejaGnu.pass("InteractiveObject::accessibilityImplementation
property exists");
+ } else {
+ DejaGnu.fail("InteractiveObject::accessibilityImplementation
property doesn't exist");
+ }
+ var c1:ContextMenu = new ContextMenu();
+ x1.contextMenu = c1;
+ if (Std.is(x1.contextMenu, ContextMenu)) {
+ DejaGnu.pass("InteractiveObject::contextMenu property exists");
+ } else {
+ DejaGnu.fail("InteractiveObject::contextMenu property doesn't
exist");
+ }
+ if (Std.is(x1.doubleClickEnabled, Bool)) {
DejaGnu.pass("InteractiveObject::doubleClickEnabled property
exists");
} else {
DejaGnu.fail("InteractiveObject::doubleClickEnabled property
doesn't exist");
}
-// if (x1.focusRect == Object) {
-// DejaGnu.pass("InteractiveObject::focusRect property exists");
-// } else {
-// DejaGnu.fail("InteractiveObject::focusRect property doesn't exist");
-// }
- if (x1.mouseEnabled == false) {
+ if (Std.is(x1.focusRect, Dynamic)) {
+ DejaGnu.pass("InteractiveObject::focusRect property exists");
+ } else {
+ DejaGnu.fail("InteractiveObject::focusRect property doesn't exist");
+ }
+ if (Std.is(x1.mouseEnabled, Bool)) {
DejaGnu.pass("InteractiveObject::mouseEnabled property exists");
} else {
DejaGnu.fail("InteractiveObject::mouseEnabled property doesn't
exist");
}
- if (x1.tabEnabled == false) {
+ if (Std.is(x1.tabEnabled, Bool)) {
DejaGnu.pass("InteractiveObject::tabEnabled property exists");
} else {
DejaGnu.fail("InteractiveObject::tabEnabled property doesn't
exist");
}
- if (x1.tabIndex == 0) {
+ if (Std.is(x1.tabIndex, Int)) {
DejaGnu.pass("InteractiveObject::tabIndex property exists");
} else {
DejaGnu.fail("InteractiveObject::tabIndex property doesn't exist");
@@ -83,6 +94,9 @@
// Call this after finishing all tests. It prints out the totals.
DejaGnu.done();
+#else
+ DejaGnu.note("This class (InteractiveObject) is only available in
flash9");
+#end
}
}
=== modified file 'testsuite/as3/classes.all/display/InterpolationMethod_as.hx'
--- a/testsuite/as3/classes.all/display/InterpolationMethod_as.hx
2009-05-21 00:17:43 +0000
+++ b/testsuite/as3/classes.all/display/InterpolationMethod_as.hx
2009-06-01 22:01:49 +0000
@@ -1,6 +1,6 @@
// InterpolationMethod_as.hx: ActionScript 3 "InterpolationMethod" class, for
Gnash.
//
-// Generated by gen-as3.sh on: 20090514 by "rob". Remove this
+// Generated on: 20090601 by "bnaugle". Remove this
// after any hand editing loosing changes.
//
// Copyright (C) 2009 Free Software Foundation, Inc.
@@ -26,9 +26,6 @@
#if flash9
import flash.display.InterpolationMethod;
import flash.display.MovieClip;
-#else
-import flash.InterpolationMethod;
-import flash.MovieClip;
#end
import flash.Lib;
import Type;
@@ -39,20 +36,46 @@
// Class must be named with the _as suffix, as that's the same name as the
file.
class InterpolationMethod_as {
static function main() {
+#if flash9
// Make sure we actually get a valid class
- if (InterpolationMethod.LINEAR_RGB != null) {
- DejaGnu.pass("InterpolationMethod.LINEAR_RGB constant exists");
+ if (InterpolationMethod.LINEAR_RGB != null) {
+ DejaGnu.pass("InterpolationMethod.LINEAR_RGB constant exists");
+ if (Std.is(InterpolationMethod.LINEAR_RGB, String)) {
+ DejaGnu.pass("InterpolationMethod.LINEAR_RGB is a String");
+ if (Std.string(InterpolationMethod.LINEAR_RGB) == "linearRGB") {
+ DejaGnu.pass("InterpolationMethod.LINEAR_RGB is the
correct string (linearRGB)");
+ } else {
+ DejaGnu.fail(
+ "InterpolationMethod.LINEAR_RGB is not the correct
string (Should be linearRGB, but is "+InterpolationMethod.LINEAR_RGB+")");
+ }
+ } else {
+ DejaGnu.fail("InterpolationMethod.LINEAR_RGB is not a string.
Instead, it is a "+Type.typeof(InterpolationMethod.LINEAR_RGB));
+ }
} else {
DejaGnu.fail("InterpolationMethod.LINEAR_RGB constant doesn't
exist");
}
- if (InterpolationMethod.RGB != null) {
- DejaGnu.pass("InterpolationMethod.RGB constant exists");
+ if (InterpolationMethod.RGB != null) {
+ DejaGnu.pass("InterpolationMethod.RGB constant exists");
+ if (Std.is(InterpolationMethod.RGB, String)) {
+ DejaGnu.pass("InterpolationMethod.RGB is a String");
+ if (Std.string(InterpolationMethod.RGB) == "rgb") {
+ DejaGnu.pass("InterpolationMethod.RGB is the correct
string (rgb)");
+ } else {
+ DejaGnu.fail(
+ "InterpolationMethod.RGB is not the correct string
(Should be rgb, but is "+InterpolationMethod.RGB+")");
+ }
+ } else {
+ DejaGnu.fail("InterpolationMethod.RGB is not a string. Instead,
it is a "+Type.typeof(InterpolationMethod.RGB));
+ }
} else {
DejaGnu.fail("InterpolationMethod.RGB constant doesn't exist");
}
DejaGnu.done();
+#else
+ DejaGnu.note("This class (InterpolationMethod) is only available in
flash9");
+#end
}
}
=== modified file 'testsuite/as3/classes.all/display/SWFVersion_as.hx'
--- a/testsuite/as3/classes.all/display/SWFVersion_as.hx 2009-05-21
00:17:43 +0000
+++ b/testsuite/as3/classes.all/display/SWFVersion_as.hx 2009-06-01
22:01:49 +0000
@@ -1,6 +1,6 @@
// SWFVersion_as.hx: ActionScript 3 "SWFVersion" class, for Gnash.
//
-// Generated by gen-as3.sh on: 20090514 by "rob". Remove this
+// Generated on: 20090601 by "bnaugle". Remove this
// after any hand editing loosing changes.
//
// Copyright (C) 2009 Free Software Foundation, Inc.
@@ -26,9 +26,6 @@
#if flash9
import flash.display.SWFVersion;
import flash.display.MovieClip;
-#else
-import flash.SWFVersion;
-import flash.MovieClip;
#end
import flash.Lib;
import Type;
@@ -39,68 +36,104 @@
// Class must be named with the _as suffix, as that's the same name as the
file.
class SWFVersion_as {
static function main() {
- // Make sure we actually get a valid class
-
-// FIXME: for some reason, none of thesew constants work
-// if (SWFVersion == SWFVersion.FLASH1) {
-// DejaGnu.pass("SWFVersion.FLASH1 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH1 constant doesn't exist");
-// }
-
-// if (SWFVersion == FLASH2) {
-// DejaGnu.pass("SWFVersion.FLASH2 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH2 constant doesn't exist");
-// }
-
-// if (SWFVersion.FLASH3 == 3) {
-// DejaGnu.pass("SWFVersion.FLASH3 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH3 constant doesn't exist");
-// }
-
-// if (SWFVersion.FLASH4 == 4) {
-// DejaGnu.pass("SWFVersion.FLASH4 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH4 constant doesn't exist");
-// }
-
-// if (SWFVersion.FLASH5 == 5) {
-// DejaGnu.pass("SWFVersion.FLASH5 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH5 constant doesn't exist");
-// }
-
-// if (SWFVersion.FLASH6 == 6) {
-// DejaGnu.pass("SWFVersion.FLASH6 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH6 constant doesn't exist");
-// }
-
-// if (SWFVersion.FLASH7 == 7) {
-// DejaGnu.pass("SWFVersion.FLASH7 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH7 constant doesn't exist");
-// }
-
-// if (SWFVersion.FLASH2 == 2) {
-// DejaGnu.pass("SWFVersion.FLASH2 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH2 constant doesn't exist");
-// }
-
-// if (SWFVersion.FLASH2 == 2) {
-// DejaGnu.pass("SWFVersion.FLASH2 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH2 constant doesn't exist");
-// }
-
-// if (SWFVersion.FLASH2 == 2) {
-// DejaGnu.pass("SWFVersion.FLASH2 constant exists");
-// } else {
-// DejaGnu.fail("SWFVersion.FLASH2 constant doesn't exist");
-// }
+#if flash9
+ // Make sure we actually get a valid class
+
+ if (Std.is(SWFVersion.FLASH1, Int)) {
+ DejaGnu.pass("SWFVersion.FLASH1 is an int");
+ if (Std.string(SWFVersion.FLASH1) == "1") {
+ DejaGnu.pass("SWFVersion.FLASH1 is the correct int
(1)");
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH1 is not the correct int
(Should be 1, but is "+SWFVersion.FLASH1+")");
+ }
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH1 is not an int. Instead,
it is a "+Type.typeof(SWFVersion.FLASH1));
+ }
+ if (Std.is(SWFVersion.FLASH2, Int)) {
+ DejaGnu.pass("SWFVersion.FLASH2 is an int");
+ if (Std.string(SWFVersion.FLASH2) == "2") {
+ DejaGnu.pass("SWFVersion.FLASH2 is the correct int
(2)");
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH2 is not the correct int
(Should be 2, but is "+SWFVersion.FLASH2+")");
+ }
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH2 is not an int. Instead,
it is a "+Type.typeof(SWFVersion.FLASH2));
+ }
+ if (Std.is(SWFVersion.FLASH3, Int)) {
+ DejaGnu.pass("SWFVersion.FLASH3 is an int");
+ if (Std.string(SWFVersion.FLASH3) == "3") {
+ DejaGnu.pass("SWFVersion.FLASH3 is the correct int
(3)");
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH3 is not the correct int
(Should be 3, but is "+SWFVersion.FLASH3+")");
+ }
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH3 is not an int. Instead,
it is a "+Type.typeof(SWFVersion.FLASH3));
+ }
+ if (Std.is(SWFVersion.FLASH4, Int)) {
+ DejaGnu.pass("SWFVersion.FLASH4 is an int");
+ if (Std.string(SWFVersion.FLASH4) == "4") {
+ DejaGnu.pass("SWFVersion.FLASH4 is the correct int
(4)");
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH4 is not the correct int
(Should be 4, but is "+SWFVersion.FLASH4+")");
+ }
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH4 is not an int. Instead,
it is a "+Type.typeof(SWFVersion.FLASH4));
+ }
+ if (Std.is(SWFVersion.FLASH5, Int)) {
+ DejaGnu.pass("SWFVersion.FLASH5 is an int");
+ if (Std.string(SWFVersion.FLASH5) == "5") {
+ DejaGnu.pass("SWFVersion.FLASH5 is the correct int
(5)");
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH5 is not the correct int
(Should be 5, but is "+SWFVersion.FLASH5+")");
+ }
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH5 is not an int. Instead,
it is a "+Type.typeof(SWFVersion.FLASH5));
+ }
+
+ if (Std.is(SWFVersion.FLASH6, Int)) {
+ DejaGnu.pass("SWFVersion.FLASH6 is an int");
+ if (Std.string(SWFVersion.FLASH6) == "6") {
+ DejaGnu.pass("SWFVersion.FLASH6 is the correct int
(6)");
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH6 is not the correct int
(Should be 6, but is "+SWFVersion.FLASH6+")");
+ }
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH6 is not an int. Instead,
it is a "+Type.typeof(SWFVersion.FLASH6));
+ }
+
+ if (Std.is(SWFVersion.FLASH7, Int)) {
+ DejaGnu.pass("SWFVersion.FLASH7 is an int");
+ if (Std.string(SWFVersion.FLASH7) == "7") {
+ DejaGnu.pass("SWFVersion.FLASH7 is the correct int
(7)");
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH7 is not the correct int
(Should be 7, but is "+SWFVersion.FLASH7+")");
+ }
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH7 is not an int. Instead,
it is a "+Type.typeof(SWFVersion.FLASH7));
+ }
+
+ if (Std.is(SWFVersion.FLASH8, Int)) {
+ DejaGnu.pass("SWFVersion.FLASH8 is an int");
+ if (Std.string(SWFVersion.FLASH8) == "8") {
+ DejaGnu.pass("SWFVersion.FLASH8 is the correct int
(8)");
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH8 is not the correct int
(Should be 8, but is "+SWFVersion.FLASH8+")");
+ }
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH8 is not an int. Instead,
it is a "+Type.typeof(SWFVersion.FLASH8));
+ }
+
+ if (Std.is(SWFVersion.FLASH9, Int)) {
+ DejaGnu.pass("SWFVersion.FLASH9 is an int");
+ if (Std.string(SWFVersion.FLASH9) == "9") {
+ DejaGnu.pass("SWFVersion.FLASH9 is the correct int
(9)");
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH9 is not the correct int
(Should be 9, but is "+SWFVersion.FLASH9+")");
+ }
+ } else {
+ DejaGnu.fail("SWFVersion.FLASH9 is not an int. Instead,
it is a "+Type.typeof(SWFVersion.FLASH9));
+ }
+
// Tests to see if all the methods exist. All these do is test for
// existance of a method, and don't test the functionality at all. This
@@ -108,6 +141,9 @@
// Call this after finishing all tests. It prints out the totals.
DejaGnu.done();
+#else
+ DejaGnu.note("This class (SWFVersion) is only available in flash9");
+#end
}
}
=== modified file 'testsuite/as3/classes.all/geom/Transform_as.hx'
--- a/testsuite/as3/classes.all/geom/Transform_as.hx 2009-06-01 17:24:36
+0000
+++ b/testsuite/as3/classes.all/geom/Transform_as.hx 2009-06-01 22:01:49
+0000
@@ -24,8 +24,8 @@
// DejaGnu.hx header file for the testing framework support.
#if flash9
import flash.display.MovieClip;
-import flash.geom.Matrix3D;
-import flash.geom.PerspectiveProjection;
+//import flash.geom.Matrix3D;
+//import flash.geom.PerspectiveProjection;
#end
#if flash8
import flash.MovieClip;
@@ -88,21 +88,21 @@
DejaGnu.fail("Transform.concatenatedMatrix property doesn't exist");
}
#if flash10
- if (Std.is(x1.matrix3D, Matrix3D)) {
- DejaGnu.pass("Transform.matrix3D property exists");
- } else {
- DejaGnu.fail("Transform.matrix3D property doesn't exist");
- }
- if (Std.is(x1.perspectiveProjection, PerspectiveProjection)) {
- DejaGnu.pass("Transform.perspectiveProjection property exists");
- } else {
- DejaGnu.fail("Transform.perspectiveProjection property doesn't
exist");
- }
- if (Type.typeof(x1.getRelativeMatrix3D) == ValueType.TFunction) {
- DejaGnu.pass("Transform.getRelativeMatrix3D method exists");
- } else {
- DejaGnu.fail("Transform.getRelativeMatrix3D method doesn't exist");
- }
+// if (Std.is(x1.matrix3D, Matrix3D)) {
+// DejaGnu.pass("Transform.matrix3D property exists");
+// } else {
+// DejaGnu.fail("Transform.matrix3D property doesn't exist");
+// }
+// if (Std.is(x1.perspectiveProjection, PerspectiveProjection)) {
+// DejaGnu.pass("Transform.perspectiveProjection property exists");
+// } else {
+// DejaGnu.fail("Transform.perspectiveProjection property doesn't
exist");
+// }
+// if (Type.typeof(x1.getRelativeMatrix3D) == ValueType.TFunction) {
+// DejaGnu.pass("Transform.getRelativeMatrix3D method exists");
+// } else {
+// DejaGnu.fail("Transform.getRelativeMatrix3D method doesn't exist");
+// }
#end
if (Std.is(x1.matrix, Matrix)) {
DejaGnu.pass("Transform.matrix property exists");
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gnash-commit] /srv/bzr/gnash/trunk r10961: Updated test cases and fixed geom/Transform_as.hx,
Bob Naugle <=