From 5d94695e9ad42343e72918024c046f22fe4941a0 Mon Sep 17 00:00:00 2001 From: Harshavardhana Date: Wed, 21 Aug 2013 00:50:41 -0700 Subject: tests: Create a regression-tests package for distribution As of today regression tests are an in-house breed, by making it a new package and distributing it ensures larger set of people use it and contribute to it. This can also be used by any consumer/user to build their own environment for glusterfs regression testing which is today limited only to 'upstream' 'glusterfs' releases and build.gluster.org Change-Id: I4f7e9fd1c49982dcf0d788ef6a83ffe895a956ac BUG: 764966 Signed-off-by: Harshavardhana Reviewed-on: http://review.gluster.org/5674 Reviewed-by: Niels de Vos Tested-by: Gluster Build System --- tests/README | 26 -------------------------- tests/README.md | 27 +++++++++++++++++++++++++++ tests/bugs/bug-853258.t | 2 +- 3 files changed, 28 insertions(+), 27 deletions(-) delete mode 100644 tests/README create mode 100644 tests/README.md (limited to 'tests') diff --git a/tests/README b/tests/README deleted file mode 100644 index 857230acb..000000000 --- a/tests/README +++ /dev/null @@ -1,26 +0,0 @@ -How to use test script framework. -================================= - -- Build and install the version of glusterfs with your changes. Make - sure the installed version is accessible from $PATH. - -- To mount glusterfs, NEVER use 'mount -t glusterfs', instead use - 'glusterfs -s ' method. This is because with the patch build setup - doesnot install the /sbin/mount.glusterfs necessary, where as the - glusterfs binary will be accessible with $PATH, and will pick the - right version. - -- (optional) Set environment variables to specify location of - export directories and mount points. Unless you have special - requirements, the defaults should just work. The variables - themselves can be found at the top of tests/include.rc. All - of them can be overriden with environment variables. - -- Execute run-tests.sh in the top level directory as root. - -- If some test cases fail, you can execute the failed test case script - directly bypassing run-tests.sh. At this time it might be - useful to set the envrionment variable DEBUG=1 before running - the individual test script directly by hand. - -- BE WARNED THAT THE TEST CASES DELETE /var/lib/glusterd/* !!! diff --git a/tests/README.md b/tests/README.md new file mode 100644 index 000000000..2b5ed8dcd --- /dev/null +++ b/tests/README.md @@ -0,0 +1,27 @@ +Regression tests framework for GlusterFS +======================================== + +## Prereq +- Build and install the version of glusterfs with your changes. Make + sure the installed version is accessible from $PATH. + +## How-To +- To mount glusterfs, NEVER use 'mount -t glusterfs', instead use + 'glusterfs -s ' method. This is because with the patch build setup + doesnot install the /sbin/mount.glusterfs necessary, where as the + glusterfs binary will be accessible with $PATH, and will pick the + right version. +- (optional) Set environment variables to specify location of + export directories and mount points. Unless you have special + requirements, the defaults should just work. The variables + themselves can be found at the top of tests/include.rc. All + of them can be overriden with environment variables. + +## Usage +- Execute `/usr/share/glusterfs/run-tests.sh` as root. + +- If some test cases fail, report to GlusterFS community at + `gluster-devel@nongnu.org`. + +## Reminder +- BE WARNED THAT THE TEST CASES DELETE /var/lib/glusterd/* !!! \ No newline at end of file diff --git a/tests/bugs/bug-853258.t b/tests/bugs/bug-853258.t index 0ca995551..faa9d4465 100755 --- a/tests/bugs/bug-853258.t +++ b/tests/bugs/bug-853258.t @@ -38,7 +38,7 @@ for i in $(seq 0 3); do xattrs="$xattrs $(dht_get_layout $B0/${V0}$i)" done -overlap=$($(dirname $0)/overlap.py $xattrs) +overlap=$(python2 $(dirname $0)/overlap.py $xattrs) # 2863311531 = 0xaaaaaaab = 2/3 overlap TEST [ "$overlap" -ge 2863311531 ] -- cgit