zsh-workers
 help / color / mirror / code / Atom feed
* V11db_gdbm.ztst fails on Cygwin
@ 2017-03-02 10:52 Jun T.
  2017-03-02 11:47 ` Sebastian Gniazdowski
  2017-03-02 15:16 ` Sebastian Gniazdowski
  0 siblings, 2 replies; 8+ messages in thread
From: Jun T. @ 2017-03-02 10:52 UTC (permalink / raw)
  To: zsh-workers

V11db_gdbm.ztst fails on Cygwin as:

./V11db_gdbm.ztst: starting.
--- /tmp/zsh.ztst.2148/ztst.out	2017-03-02 19:26:45.040189100 +0900
+++ /tmp/zsh.ztst.2148/ztst.tout	2017-03-02 19:26:45.055788600 +0900
@@ -1,4 +1,4 @@
-c
-d
 a
 b
+c
+d
Test ./V11db_gdbm.ztst failed: output differs from expected as shown above for:
 ztie -d db/gdbm -f $dbfile dbase
 dbase=( a b c d )
 zuntie dbase
 ztie -d db/gdbm -f $dbfile dbase
 print -rl -- "${(kv)dbase[@]}"
 zuntie dbase
Was testing: replace hash / database, scan
./V11db_gdbm.ztst: test failed.


${(k)dabse} gives 'a c', instead of 'c a' as expeced by the test.

The order the records are visited by gdbm_{firstkey,nextkey}()
depends on the hash values used by gdbm, and (due to some reason
unknown to me) it seems the hash values used on Cygwin are different
from those used on Linux. The gdbm I'm using on Cygwin is from the
Cygwin's package repository (binary distribution).

Is it really necessary to test that gdbm_{firstkey,nextkey}()
gives the same order on different OSs?

PS
On macOS V11db_gdbm.ztst succeeds (with gdbm built by myself from
the gdbm source).

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2017-03-03 12:06 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-02 10:52 V11db_gdbm.ztst fails on Cygwin Jun T.
2017-03-02 11:47 ` Sebastian Gniazdowski
2017-03-02 11:54   ` Peter Stephenson
2017-03-02 11:54   ` Daniel Shahaf
2017-03-02 12:14     ` Sebastian Gniazdowski
2017-03-02 15:16 ` Sebastian Gniazdowski
2017-03-02 23:56   ` Jun T.
2017-03-03 11:06   ` 淳一 滝本

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

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 NNTP newsgroup(s).