summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKent Fredric <kentnl@gentoo.org>2020-11-14 22:25:18 +1300
committerKent Fredric <kentnl@gentoo.org>2020-11-14 22:32:55 +1300
commitfa7707eec220899ef409de56d9e90a0df79ae238 (patch)
treef21fd97410f00c0c3b44e550bff4d421bd11d746 /app-admin
parentapp-admin/rex: -9999 strip authortests w/ false-postive missing deps (diff)
downloadgentoo-fa7707eec220899ef409de56d9e90a0df79ae238.tar.gz
gentoo-fa7707eec220899ef409de56d9e90a0df79ae238.tar.bz2
gentoo-fa7707eec220899ef409de56d9e90a0df79ae238.zip
app-admin/rex: -9999 strip db.t if it would break tests
Test::mysqld is still a work in progress to get working. If you managed to DIY something that installs, but didn't do the magic required for it to actually work, then db.t will break. This tests for basic conditions and strips that file *only* if its expected it will lead to a test failure. If you've manually installed Test::mysqld and tweaked a PATH to include "mysql_install_db", then this test should be retained and pass. Package-Manager: Portage-3.0.8, Repoman-3.0.1 Signed-off-by: Kent Fredric <kentnl@gentoo.org>
Diffstat (limited to 'app-admin')
-rw-r--r--app-admin/rex/rex-9999.ebuild9
1 files changed, 8 insertions, 1 deletions
diff --git a/app-admin/rex/rex-9999.ebuild b/app-admin/rex/rex-9999.ebuild
index f3a8a74be862..2d05b364666e 100644
--- a/app-admin/rex/rex-9999.ebuild
+++ b/app-admin/rex/rex-9999.ebuild
@@ -81,7 +81,7 @@ RDEPEND="
dev-perl/YAML
virtual/perl-version
"
-
+# NB: would add test? !minimal? Test-mysqld, but I can't get that to work
BDEPEND="
${RDEPEND}
>=virtual/perl-CPAN-Meta-Requirements-2.120.620
@@ -196,6 +196,13 @@ src_prepare() {
dzil_to_distdir "${EGIT_CHECKOUT_DIR}" "${S}"
fi
cd "${S}" || die "Can't enter build dir"
+
+ # If you DIY installed Test::mysqld, but didn't patch
+ # it to handle the fact on Gentoo, mysql_install_db is NOT in PATH
+ # tests fail. So this test is patched out if mysql_install_db is not in PATH
+ if perl_has_module "Test::mysqld" && ! type -P mysql_install_db >/dev/null; then
+ perl_rm_files "t/db.t"
+ fi
perl-module_src_prepare
}