gnash-commit
[Top][All Lists]
Advanced

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

[Gnash-commit] gnash/testsuite/misc-ming.all gotoFrame2Test.as


From: Sandro Santilli
Subject: [Gnash-commit] gnash/testsuite/misc-ming.all gotoFrame2Test.as
Date: Wed, 21 Feb 2007 11:19:45 +0000

CVSROOT:        /sources/gnash
Module name:    gnash
Changes by:     Sandro Santilli <strk>  07/02/21 11:19:45

Modified files:
        testsuite/misc-ming.all: gotoFrame2Test.as 

Log message:
        Made the test properly print totals and stop. Works fine with Gnash.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/misc-ming.all/gotoFrame2Test.as?cvsroot=gnash&r1=1.1&r2=1.2

Patches:
Index: gotoFrame2Test.as
===================================================================
RCS file: /sources/gnash/gnash/testsuite/misc-ming.all/gotoFrame2Test.as,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -b -r1.1 -r1.2
--- gotoFrame2Test.as   21 Feb 2007 10:58:56 -0000      1.1
+++ gotoFrame2Test.as   21 Feb 2007 11:19:45 -0000      1.2
@@ -3,17 +3,22 @@
 
 // This code is in frame #2 of a 3-frame file!
 
-note("Executing actions in frame "+_currentframe+", counter = "+counter);
-if ( ++counter < 2 ) {
-       var temp = _currentframe;
-       check_equals(temp, 2);
-       //gotoAndPlay(temp); // this is just a function call, and works fine
-       note("About to execute GOTOFRAME2");
-       gotoFrame(temp); // this emits a GOTOFRAME2 tag
-       note("After GOTOFRAME2, _currentframe is "+_currentframe);
-       check_equals(_currentframe, temp);
-} else {
-       totals();
-       stop();
-}
+++counter;
+
+var temp = _currentframe;
+
+check_equals(temp, 2);
+check_equals(counter, 1);
+
+// this would emit a function call
+//gotoAndPlay(temp);
+
+// this emits a GOTOFRAME2 tag
+gotoFrame(temp);
+
+check_equals(_currentframe, temp);
+check_equals(counter, 1); // gotoFrame(_currentframe) is a no-op
+
+totals();
+stop();
  




reply via email to

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