path: root/tests/
Commit message (Collapse)AuthorAgeFilesLines
* Regression test portability: batch of bugs (volume 2)Emmanuel Dreyfus2014-11-261-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix various regression test portability in tests/bugs. bug-861542.t - Avoid syntax specific to GNU sed. bug-860663.t - Command argument length is system dependent, and specifying 1000 file path may overflow it. Use a C program to do the job in a portable and efficient way. - Add a test that we created the specified amount of files. bug-858242.c, bug-808400-fcntl.c, bug-808400-flock.c - fstat64() is Linux-specific. Define it as fstat for other systems. bug-823081.t - Use portable tail -n instead of tail --lines In many tests: - Do not assume python interpreter name. Use $PYTHON as defined in env.rc by configure. utils/ - If python version is 2.6 or higher, use a portable mechanism to recover errno. The original version is retained for python version 2.5 and earlier but it only works on Linux. BUG: 1129939 Change-Id: If2fea1ffec5cc6ab2de426fb200e884450afe61b Signed-off-by: Emmanuel Dreyfus <> Reviewed-on: Tested-by: Gluster Build System <> Reviewed-by: Vijay Bellur <>
* glupy: portability fixesEmmanuel Dreyfus2014-11-051-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes portability problems so that NetBSD passes tests/features/glupy.t - Use python-config to detect python build environment on all systems, not just Linux and Darwin. - Get the site-package directory from python and make sure we install there, Previously we installed within glusterfs prefix, which caused a problem if it was different that python's prefix. - Set PYTHONPATH for tests so that the detected site-packages is used in python's search path. This should be useless, but let us have it just in case. - Pass path from glusterfsd to through an environment variable and use it in CDLL instead of "", as the later seems not portable (at least it fails on NetBSD). - Use gil_init_key pthread_getspecific to avoid deadlocks (that code was #ifdef out, perhaps because it was not needed on Linux, but it seems to be required for NetBSD. - Recover the error message from Python and send it to the logs to help debugging problems. BUG: 1129939 Change-Id: Icc71e77d6940f0759cc14c5c5cf7ca6fa431e0d2 Signed-off-by: Emmanuel Dreyfus <> Reviewed-on: Tested-by: Gluster Build System <> Reviewed-by: Jeff Darcy <>
* build: make GLUSTERD_WORKDIR rely on localstatedirHarshavardhana2014-08-071-0/+11
- Break-way from '/var/lib/glusterd' hard-coded previously, instead rely on 'configure' value from 'localstatedir' - Provide 's/lib/db' as default working directory for gluster management daemon for BSD and Darwin based installations - loff_t is really off_t on Darwin - fix-off the warnings generated by clang on FreeBSD/Darwin - Now 'tests/*' use GLUSTERD_WORKDIR a common variable for all platforms. - Define proper environment for running tests, define correct PATH and LD_LIBRARY_PATH when running tests, so that the desired version of glusterfs is used, regardless where it is installed. (Thanks to for this additional work) Change-Id: I2339a0d9275de5939ccad3e52b535598064a35e7 BUG: 1111774 Signed-off-by: Harshavardhana <> Signed-off-by: Emmanuel Dreyfus <> Reviewed-on: Tested-by: Gluster Build System <>