public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* FYI: remove failing python test
@ 2010-06-04 17:34 Tom Tromey
  0 siblings, 0 replies; only message in thread
From: Tom Tromey @ 2010-06-04 17:34 UTC (permalink / raw)
  To: gdb-patches

I'm checking this in.

This test was failing on my x86 box:

    gdb_test "python print one.__hash__() == id(one)" "True" "Test inbuilt id"

I tracked this down to a difference between Python's built in "id"
function and Value.__hash__: we sign extend and id does not.

We could fix this difference, but there is really nothing too wrong with
our hash function, and I don't think it is advisable to rely on exactly
how 'id' is implemented.

So, I'm removing the test.

Tom

2010-06-04  Tom Tromey  <tromey@redhat.com>

	* gdb.python/py-value.exp (test_value_hash): Don't test equality
	of hash and id.

Index: gdb.python/py-value.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.python/py-value.exp,v
retrieving revision 1.11
diff -u -r1.11 py-value.exp
--- gdb.python/py-value.exp	3 Jun 2010 23:54:18 -0000	1.11
+++ gdb.python/py-value.exp	4 Jun 2010 16:32:26 -0000
@@ -406,7 +406,6 @@
     gdb_test "python print vdict\[two\]" "two str" "Test dictionary hash"
     gdb_test "python print vdict\[three\]" "three str" "Test dictionary hash"
     gdb_test "python print one.__hash__() == hash(one)" "True" "Test inbuilt hash"
-    gdb_test "python print one.__hash__() == id(one)" "True" "Test inbuilt id"
 }
 
 

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-06-04 17:34 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-04 17:34 FYI: remove failing python test Tom Tromey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).