gnash-commit
[Top][All Lists]
Advanced

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

[Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_final-


From: Bastiaan Jacques
Subject: [Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_final-1660-g906e67a
Date: Fri, 12 Jul 2013 20:11:36 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Gnash".

The branch, master has been updated
       via  906e67a84723d25a0d1aecfbbe76f4a1aa511844 (commit)
      from  6dba36f07216f6923960a7df470456df109d3749 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit//commit/?id=906e67a84723d25a0d1aecfbbe76f4a1aa511844


commit 906e67a84723d25a0d1aecfbbe76f4a1aa511844
Author: Bastiaan Jacques <address@hidden>
Date:   Fri Jul 12 22:10:13 2013 +0200

    Savannah #39385: Add a test.

diff --git a/testsuite/actionscript.all/array.as 
b/testsuite/actionscript.all/array.as
index c1cc220..0417419 100644
--- a/testsuite/actionscript.all/array.as
+++ b/testsuite/actionscript.all/array.as
@@ -324,6 +324,24 @@ trysortarray.sort( testCmpBogus6 );
 check_equals ( trysortarray.length, 4 );
 xcheck_equals ( trysortarray.toString(), "2,3,4,1" );
 
+// This comparator is total nonsense, but there are people using this to
+// randomize their array, and we must oblige by not aborting. (See #39385.)
+function randomComparator(a, b) {
+   return Math.random() < 0.5 ? -1 : 1;
+}
+
+var indexedarray = new Array(10,9,8,3,2,1,0);
+indexedarray = indexedarray.sort(randomComparator, Array.RETURNINDEXEDARRAY);
+
+check_equals ( indexedarray.length, 7 );
+
+var firstRandom = indexedarray.toString();
+indexedarray = indexedarray.sort(randomComparator, Array.RETURNINDEXEDARRAY);
+var secondRandom = indexedarray.toString();
+
+// I suppose it is theoretically possible that these are the same. But it
+// seems very unlikely.
+check(firstRandom != secondRandom);
 
 //-----------------------------------------------------
 // Test non-integer and insane indices.
@@ -1795,11 +1813,11 @@ check_equals(ar.__proto__, "string");
 //
 
 #if OUTPUT_VERSION < 6
- check_totals(550);
+ check_totals(552);
 #else
 # if OUTPUT_VERSION < 7
-  check_totals(634);
+  check_totals(636);
 # else
-  check_totals(644);
+  check_totals(646);
 # endif
 #endif

-----------------------------------------------------------------------

Summary of changes:
 testsuite/actionscript.all/array.as |   24 +++++++++++++++++++++---
 1 files changed, 21 insertions(+), 3 deletions(-)


hooks/post-receive
-- 
Gnash



reply via email to

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