Running the VOMS core test suite
Prerequisites
The VOMS core test suite is strictly bound to the VOMS compilation process, so, in order to run it, you need to have all the build-time dependencies
needed to compile VOMS core with the addition of
dejagnu
.
Running the testsuite as a normal user
These instructions provide insight on how the VOMS testsuite can be run without root privileges.
Let's say that
/home/ceccanti/voms-installation
will be the installation root for your VOMS installation.
You need to configure voms and the database backend plugin that you will be using (e.g.,
voms-mysql-plugin
) so that they
point to the above installation root.
Checkout VOMS source code
git clone git://github.com/italiangrid/voms.git
git checkout <THE_VOMS_TAG_TO_BE_TESTED>
Checkout VOMS mysql plugin source code
git clone git://github.com/italiangrid/voms-mysql-plugin.git
git checkout <THE_VOMS_TAG_TO_BE_TESTED>
Configure the VOMS build
cd <voms-source-directory>
./autogen.sh
./configure --host=x86_64-redhat-linux-gnu --build=x86_64-redhat-linux-gnu \
--target=x86_64-redhat-linux \
--program-prefix= \
--prefix=/home/ceccanti/voms-installation/usr \
--exec-prefix=/home/ceccanti/voms-installation/usr \
--bindir=/home/ceccanti/voms-installation/usr/bin \
--sbindir=/home/ceccanti/voms-installation/usr/sbin \
--sysconfdir=/home/ceccanti/voms-installation/etc \
--datadir=/home/ceccanti/voms-installation/usr/share \
--includedir=/home/ceccanti/voms-installation/usr/include \
--libdir=/home/ceccanti/voms-installation/usr/lib64 \
--libexecdir=/home/ceccanti/voms-installation/usr/libexec \
--localstatedir=/home/ceccanti/voms-installation/var \
--sharedstatedir=/home/ceccanti/voms-installation/usr/com \
--mandir=/home/ceccanti/voms-installation/usr/share/man \
--infodir=/home/ceccanti/voms-installation/usr/share/info \
--with-vomsuser='' \
--with-dbuser=root \
--with-dbpwd=pwd \
--with-mysqlconf=/etc/my.cnf \
--with-report-dir=/tmp/voms-reports \
--with-scratch-dir=/tmp/voms-scratch
Configure option |
Meaning |
--with-vomsuser |
The user that will be used to run VOMS. It must be set to the empty string to avoid the default (ROOT). |
--with-dbuser, --with-dbpwd |
Database access credentials. |
--with-mysqlconf |
The configuration for the mysql database (typically /etc/my.cnf ) |
--with-report-dir |
The directory in which the testsuite reports will be placed. |
--with-scratch-dir |
The testsuite work directory. |
Compile and install VOMS server code
cd <voms-source-directory>
make
make install
Configure the VOMS Mysql Plugin build
The configuration for the VOMS oracle plugin is equivalent.
cd <voms-mysql-plugin-source-directory>
./autogen.sh
./configure --host=x86_64-redhat-linux-gnu --build=x86_64-redhat-linux-gnu \
--target=x86_64-redhat-linux \
--program-prefix= \
--prefix=/home/ceccanti/voms-installation/usr \
--exec-prefix=/home/ceccanti/voms-installation/usr \
--bindir=/home/ceccanti/voms-installation/usr/bin \
--sbindir=/home/ceccanti/voms-installation/usr/sbin \
--sysconfdir=/home/ceccanti/voms-installation/etc \
--datadir=/home/ceccanti/voms-installation/usr/share \
--includedir=/home/ceccanti/voms-installation/usr/include \
--libdir=/home/ceccanti/voms-installation/usr/lib64 \
--libexecdir=/home/ceccanti/voms-installation/usr/libexec \
--localstatedir=/home/ceccanti/voms-installation/var \
--sharedstatedir=/home/ceccanti/voms-installation/usr/com \
--mandir=/home/ceccanti/voms-installation/usr/share/man \
--infodir=/home/ceccanti/voms-installation/usr/share/info
Compile and install VOMS MySQL plugin
cd <voms-mysql-plugin-source-directory>
make
make install
Running the testsuite
Before running the testsuite make sure that you create by hand the scratch dir created by the voms testsuite.
The directory is the same that you specified in the
--with-scratch-dir
opion when configuring the voms build.
For example:
mkdir /tmp/voms-scratch
Now you can run the testsuite:
cd <voms-source-directory>
make check
The output of the execution of the testsuite can be found in the directory specified with the
--with-report-dir
option at configuration time.
It is composed of an
index.html
file containing the summary of the test execution.
--
AndreaCeccanti - 2012-03-01