gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] gnash ChangeLog testsuite/actionscript.all/Make...


From: Sandro Santilli
Subject: [Gnash-commit] gnash ChangeLog testsuite/actionscript.all/Make...
Date: Mon, 03 Jul 2006 17:55:34 +0000

CVSROOT:        /sources/gnash
Module name:    gnash
Changes by:     Sandro Santilli <strk>  06/07/03 17:55:34

Modified files:
        .              : ChangeLog 
        testsuite/actionscript.all: Makefile.am 
Added files:
        testsuite/actionscript.all: inheritance.as 

Log message:
        New ActionScript inheritance test

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.461&r2=1.462
http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/actionscript.all/Makefile.am?cvsroot=gnash&r1=1.26&r2=1.27
http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/actionscript.all/inheritance.as?cvsroot=gnash&rev=1.1

Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.461
retrieving revision 1.462
diff -u -b -r1.461 -r1.462
--- ChangeLog   1 Jul 2006 23:24:49 -0000       1.461
+++ ChangeLog   3 Jul 2006 17:55:34 -0000       1.462
@@ -1,3 +1,9 @@
+2006-07-03 Sandro Santilli <address@hidden>
+
+       * testsuite/actionscript.all/Makefile.am,
+       testsuite/actionscript.all/inheritance.as:
+       New ActionScript inheritance test.
+
 2006-07-02 Sandro Santilli <address@hidden>
 
        * server/ActionExecp.cpp: dump stack after each action execution

Index: testsuite/actionscript.all/Makefile.am
===================================================================
RCS file: /sources/gnash/gnash/testsuite/actionscript.all/Makefile.am,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -b -r1.26 -r1.27
--- testsuite/actionscript.all/Makefile.am      20 Jun 2006 22:50:54 -0000      
1.26
+++ testsuite/actionscript.all/Makefile.am      3 Jul 2006 17:55:34 -0000       
1.27
@@ -88,7 +88,8 @@
        Inheritance.swf         \
        NetConnection.swf       \
        XML.swf                 \
-       Function.swf            
+       Function.swf            \
+       inheritance.swf
 
 EXTRA_DIST = $(GENERATED:.swf=.as)
 

Index: testsuite/actionscript.all/inheritance.as
===================================================================
RCS file: testsuite/actionscript.all/inheritance.as
diff -N testsuite/actionscript.all/inheritance.as
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ testsuite/actionscript.all/inheritance.as   3 Jul 2006 17:55:34 -0000       
1.1
@@ -0,0 +1,72 @@
+// 
+//   Copyright (C) 2005, 2006 Free Software Foundation, Inc.
+//
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation; either version 2 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+//
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+//
+// Linking Gnash statically or dynamically with other modules is making a
+// combined work based on Gnash. Thus, the terms and conditions of the GNU
+// General Public License cover the whole combination.
+//
+// As a special exception, the copyright holders of Gnash give you
+// permission to combine Gnash with free software programs or libraries
+// that are released under the GNU LGPL and with code included in any
+// release of Talkback distributed by the Mozilla Foundation. You may
+// copy and distribute such a system following the terms of the GNU GPL
+// for all but the LGPL-covered parts and Talkback, and following the
+// LGPL for the LGPL-covered parts.
+//
+// Note that people who make modified versions of Gnash are not obligated
+// to grant this special exception for their modified versions; it is their
+// choice whether to do so. The GNU General Public License gives permission
+// to release a modified version without this exception; this exception
+// also makes it possible to release a modified version which carries
+// forward this exception.
+//
+//
+// Test case for Function ActionScript class
+// compile this test case with Ming makeswf, and then
+// execute it like this gnash -1 -r 0 -v out.swf
+
+rcsid="$Id: inheritance.as,v 1.1 2006/07/03 17:55:34 strk Exp $";
+
+#include "check.as"
+
+var obj = new Object({a:1});
+
+check_equals(obj.__proto__.constructor, Object);
+check(obj instanceOf Object);
+
+function SubObj1() {}
+var sobj1 = new SubObj1();
+
+check_equals(sobj1.__proto__.constructor, SubObj1);
+check(SubObj1 instanceOf Function);
+check(Function instanceOf Object);
+check(SubObj1 instanceOf Object);
+
+// inheritance chain is NOT subobj1,SubObj1,Function,Object, as the
+// above might suggest...
+check(! sobj1 instanceOf Function);
+
+// but still, sobj1 is an instance of Object *and* SubObj1
+check(sobj1 instanceOf Object);
+check(sobj1 instanceOf SubObj1);
+
+check(SubObj1.prototype != undefined);
+check_equals(SubObj1.prototype.constructor, SubObj1);
+
+check_equals(SubObj1.prototype.constructor.__proto__.constructor, Function);
+




reply via email to

[Prev in Thread] Current Thread [Next in Thread]