hydra/tests/Makefile.am

77 lines
2.1 KiB
Makefile
Raw Normal View History

2011-11-30 17:03:50 +00:00
TESTS_ENVIRONMENT = \
BZR_HOME="$(abs_builddir)/data" \
HYDRA_DBI="dbi:SQLite:db.sqlite" \
2011-11-30 17:03:50 +00:00
HYDRA_DATA="$(abs_builddir)/data" \
2011-03-16 16:18:59 +00:00
HYDRA_HOME="$(top_srcdir)/src" \
NIX_REMOTE= \
2011-03-17 13:25:27 +00:00
NIX_CONF_DIR="$(abs_builddir)/nix/etc/nix" \
2011-03-17 07:43:33 +00:00
NIX_STATE_DIR="$(abs_builddir)/nix/var/nix" \
2011-04-19 11:55:49 +00:00
NIX_MANIFESTS_DIR="$(abs_builddir)/nix/var/nix/manifests" \
2011-03-17 07:43:33 +00:00
NIX_STORE_DIR="$(abs_builddir)/nix/store" \
NIX_LOG_DIR="$(abs_builddir)/nix/var/log/nix" \
NIX_BUILD_HOOK= \
2012-03-12 20:06:42 +00:00
PERL5LIB="$(srcdir):$(top_srcdir)/src/lib:$$PERL5LIB" \
PATH=$(abs_top_srcdir)/src/script:$(abs_top_srcdir)/src/c:$$PATH \
2011-03-16 10:27:32 +00:00
perl -w
EXTRA_DIST = \
$(wildcard *.pm) \
$(wildcard jobs/*.nix) \
$(wildcard jobs/*.sh) \
$(TESTS)
2011-03-16 08:50:31 +00:00
TESTS = \
query-all-tables.pl \
evaluation-tests.pl
2011-03-16 13:18:12 +00:00
clean :
chmod -R a+w nix || true
2011-03-17 08:48:27 +00:00
rm -rf db.sqlite data nix git-repo hg-repo svn-repo svn-checkout svn-checkout-repo bzr-repo bzr-checkout-repo
2011-03-16 08:50:31 +00:00
2011-11-30 17:03:50 +00:00
check_SCRIPTS = db.sqlite repos
2011-03-16 08:50:31 +00:00
2011-03-16 09:24:18 +00:00
db.sqlite : $(top_srcdir)/src/sql/hydra-sqlite.sql
2012-03-12 20:06:42 +00:00
$(TESTS_ENVIRONMENT) $(top_srcdir)/src/script/hydra-init
2011-03-16 08:50:31 +00:00
2011-03-17 09:14:48 +00:00
repos : dirs git-repo hg-repo svn-repo svn-checkout-repo bzr-repo bzr-checkout-repo
dirs :
2011-03-16 09:46:47 +00:00
mkdir -p data
2011-03-16 10:50:50 +00:00
touch data/hydra.conf
2011-03-16 10:27:32 +00:00
mkdir -p nix
2011-03-17 13:25:27 +00:00
mkdir -p nix/etc/nix
touch nix/etc/nix/nix.conf
2011-03-16 10:27:32 +00:00
mkdir -p nix/store
mkdir -p nix/var
2011-03-16 14:00:52 +00:00
git-repo :
git init git-repo
touch git-repo/git-file
(cd git-repo; git add git-file ; git commit -m "add git file" git-file)
2011-03-16 14:00:52 +00:00
hg-repo :
hg init hg-repo
touch hg-repo/hg-file
(cd hg-repo; hg add hg-file ; hg commit -m "add hg file" hg-file -u foobar)
2011-03-16 14:00:52 +00:00
svn-repo :
svnadmin create svn-repo
2011-03-17 07:25:23 +00:00
svn co file://$(abs_builddir)/svn-repo svn-checkout
touch svn-checkout/svn-file
svn add svn-checkout/svn-file
svn commit -m "add svn file" svn-checkout/svn-file
2011-03-17 07:55:44 +00:00
bzr-repo :
bzr init bzr-repo
2011-03-17 09:14:48 +00:00
BZR_HOME=$(abs_builddir)/data bzr whoami "build <build@donotemail.com>" -d bzr-repo
2011-03-17 07:55:44 +00:00
touch bzr-repo/bzr-file
bzr add bzr-repo/bzr-file
2011-03-17 09:14:48 +00:00
BZR_HOME=$(abs_builddir)/data bzr commit -m "add bzr-file" bzr-repo/bzr-file
2011-03-17 08:48:27 +00:00
svn-checkout-repo :
ln -s svn-repo svn-checkout-repo
bzr-checkout-repo :
ln -s bzr-repo bzr-checkout-repo
2011-03-17 09:14:48 +00:00