Skip to content

Commit

Permalink
Merge pull request #217 from jlebon/pr/local-test-repo
Browse files Browse the repository at this point in the history
test-ucontainer.sh: use test-repo in srcdir
  • Loading branch information
cgwalters committed Feb 24, 2016
2 parents a2c052b + 1c81b7f commit 9a0a59f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
6 changes: 6 additions & 0 deletions Makefile-tests.am
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,18 @@ tests/compose/yum/repodata/repomd.xml: tests/compose/yum/empty tests/compose/yum
tests/compose/test-repo.repo: tests/compose/test-repo.repo.in tests/compose/yum/repodata/repomd.xml
cat $< | sed -e "s|%WHERE%|$(installed_testdir)|" > $@

# A version of the repo that points directly to the srcdir (for uninstalled tests)
tests/compose/test-repo-local.repo: tests/compose/test-repo.repo.in tests/compose/yum/repodata/repomd.xml
cat $< | sed -e "s|%WHERE%|$(shell pwd)|" > $@

tests_jsonutil_CPPFLAGS = -I $(srcdir)/src/libpriv
tests_jsonutil_CFLAGS = $(PKGDEP_RPMOSTREE_CFLAGS)
tests_jsonutil_LDADD = $(PKGDEP_RPMOSTREE_LIBS) librpmostreepriv.la

tests/test-compose.sh: tests/compose/test-repo.repo

tests/test-ucontainer.sh: tests/compose/test-repo-local.repo

installed_test_data = tests/libtest.sh \
tests/compose/test-repo.repo \
tests/compose/test-repo.json \
Expand Down
8 changes: 7 additions & 1 deletion tests/test-ucontainer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,13 @@ if test -d ${SRCDIR}/compose; then
else
composedatadir=${SRCDIR}
fi
cp ${composedatadir}/test-repo.repo rpmmd.repos.d

REPO=test-repo
if test -n "${UNINSTALLEDTESTS:-}"; then
REPO=test-repo-local
fi

cp ${composedatadir}/$REPO.repo rpmmd.repos.d

cat >empty.conf <<EOF
[tree]
Expand Down

0 comments on commit 9a0a59f

Please sign in to comment.