path: root/
Commit message (Collapse)AuthorAgeFilesLines
* tests/vagrant: install additional dependenciesNiels de Vos2018-06-191-0/+4
| | | | | | | | | | | | | | | The Vagrant box that is used by ./ does not have all recent dependencies installed. By using 'dnf builddep' to install the BuildRequires from the generated .spec file, most future problems should be prevented. The tests/basic/afr/split-brain-favorite-child-policy.t script uses the 'bc' command. This it a run-time dependency for the test, and will not be found with 'dnf builddep'. Change-Id: Ifdbfc4af2997ea27815126766cc093947ddf523f BUG: 1526780 Signed-off-by: Niels de Vos <>
* tests: should return test statusNiels de Vos2018-05-281-5/+17
| | | | | | | | | | | The ./ script does not return the correct exit status. Even if the tests in the Vagrant VM fail, the script returns success. This throws off the expectations that any regular testers (or CI) have. BUG: 1546103 Change-Id: I7f00903f9fe4ef3be8ba80db0f9aa8d412502b86 Signed-off-by: Niels de Vos <>
* tests/vagrant: add a --help option to the scriptNiels de Vos2017-12-271-2/+18
| | | | | | Change-Id: I89913375fedb6a7617873b09039de72bf1773c68 BUG: 1526780 Signed-off-by: Niels de Vos <>
* tests/vagrant: configure with --enable-gnfs so tests can use NFSNiels de Vos2017-12-221-0/+1
| | | | | | | | | | gNFS has been deprecated a while ago, but the ./ script has not been adapted to enable it. This causes the tests to fail the first time a Gluster Volume is mounted over NFSv3. Change-Id: Ifeec0ca964680ff61b956a5592a76eeee8ac3b85 BUG: 1526780 Signed-off-by: Niels de Vos <>
* vagrant-test: added more options and centos6 base boxRaghavendra Talur2016-04-251-126/+200
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Options added are 1. destroy-now option Now you can call with --destroy-now option to destroy the VM corresponding to the git branch and delete the corresponding vagrant dir. Usage: --destroy-now 2. os option With --os option you can specify the os to be used for VM. Default is fedora and this patch adds support for centos6. Usage: --os="centos6" 3. destroy-after-test option When specified the VM is deleted right after the tests are executed. If the script exited before running tests then the VM is left as is for further debugging. 4. verbose option Many log messages which were mainly added for initial debugging have been removed now. All vagrant and compilation outputs have been redirected to /dev/null. To enable these logs please use --verbose option. 5. ssh option --ssh option now allows one to ssh into the VM from topdir of source code thereby avoiding the hassle of cd'ing into the vagrant dir. Box added 1. This patch adds a centos6 base box which is currently made available at Template files for this box are available under tests/vagrant/vagrant-template-centos6 directory. The default box is moved under vagrant-template-fedora directory to keep up with the naming convention. Enhancements This patch also modifies the cpu and memory allocation mechanism for the VMs. All the cpus on the host are used and 1/4 of the memory available on host is used. Bug Fixes 1. Fix CFLAGS not passed to configure error If CFLAGS is assigned and then configure is called under sudo, the cflags are not passed onto configure. Change-Id: Iee1811a7d2b77785f6167f4706135a8f584a6bbd BUG: 1291537 Signed-off-by: Raghavendra Talur <> Reviewed-on: Smoke: Gluster Build System <> NetBSD-regression: NetBSD Build System <> CentOS-regression: Gluster Build System <> Reviewed-by: Jeff Darcy <>
* tests: improve vagrant usabilityJeff Darcy2016-04-061-2/+2
| | | | | | | | | | | | | | | | | | | The first and most important change is to deal with the fact that "localhost" is an IPv6 address in the vagrant box we're using. This was non-obviously behind some of the NFS tests failing to run properly, so there's now an Ansible role etc. to make the necessary modifications in /etc/hosts. Also added "-j" to the make command, and changed the invocation of "" so it passes through any arguments instead of running all tests every time. BUG: 1291537 Change-Id: I5e6125de043c41fdb2866875e999cb1fcd72ba52 Signed-off-by: Jeff Darcy <> Reviewed-on: NetBSD-regression: NetBSD Build System <> CentOS-regression: Gluster Build System <> Reviewed-by: Raghavendra Talur <> Smoke: Gluster Build System <>
* vagrant-test: Provide option to autostart vm on host bootRaghavendra Talur2016-02-251-2/+26
| | | | | | | | | | | | | | | | | | If the machines are being used as test machines for active development, user might want to have them autostart on host boot. You can use -a as short option or --autostart as longoption with to set the autostart flag on the VM. The autostart value is set to off by default. It is done using virsh until vagrant-libvirt supports it in the API. Change-Id: I5b53ea6d850c991d548dbac0bb8fadd528cabf41 BUG: 1291537 Signed-off-by: Raghavendra Talur <> Reviewed-on: Smoke: Gluster Build System <> CentOS-regression: Gluster Build System <> NetBSD-regression: NetBSD Build System <>
* vagrant-tests: Fix bug when git branch name has a /Raghavendra Talur2016-02-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | It is possible for a git branch to have a / in it. Source copy from host to VM used relative path on the assumption that VM vagrant dir will always be three levels down the topdir of repo. This assumption breaks when git branch has a / in it. Of the two solutions to fix it: a. Mangle the git branch name to not have a / b. Accomodate the possibility of have a / in git branch name. I have chosen b) because that looks cleaner. Change-Id: I6b71c31da2f5f7c349d6d6882767768b2534d14f BUG: 1291537 Signed-off-by: Raghavendra Talur <> Reviewed-on: Smoke: Gluster Build System <> NetBSD-regression: NetBSD Build System <> CentOS-regression: Gluster Build System <> Reviewed-by: Niels de Vos <>
* vagrant-test: Exit on critical errorsRaghavendra Talur2016-01-061-15/+69
| | | | | | | | | | | | | | | | There were quite a few places where exiting the script made more sense. More debug messages have been added. Move back to top directory after the script is complete. Change-Id: I2a66ee3a68c41a3acd0b7168c56b801fb5567e5f BUG: 1291537 Signed-off-by: Raghavendra Talur <> Reviewed-on: Tested-by: Gluster Build System <> Reviewed-by: Michael Adam <>
* tests: Introduce a Vagrant VM based test environmentRaghavendra Talur2015-12-281-0/+126
This introduces a mechanism using which a developer could easily test the Gluster code in a VM environment. Also, it will help bring uniformity in the environments used by various developers. How to use: 1. git checkout -b custom-branch-name 2. Make changes 3. Execute ./ What happens in the background: 1. A new directory is created: tests/vagrant/vagrant-custom-branch-name It will serve as the Vagrant dir which has the Vagrantfile and related ansible playbooks. The VM is started using Vagrant and provisioned using ansible. 2. The source dir is recursively copied over to the VM under /home/vagrant/glusterfs. 3. Gluster is source installed in VM. What happens in the foreground: 1. is executed in VM using ssh and output is displayed in the same terminal with option to use ctrl-c to interrupt the test midway. The VM would still persist and you could ssh into it. Also, you can checkout a different branch elsewhere and execute there to get another VM which would execute tests on that code. If you wish to make some changes in the code, you could: a. Change the code in host and run the script again to repeat the whole process. OR b. vagrant ssh into the VM and make the changes in the VM. Co-authored-by: Kaushal M <> Co-authored-by: Michael Adam <> Change-Id: Ic87801172c8b614cdecbdf2a765e1b3370a5faf7 BUG: 1291537 Signed-off-by: Michael Adam <> Signed-off-by: Raghavendra Talur <> Reviewed-on: Tested-by: Gluster Build System <> Reviewed-by: Niels de Vos <>