[dev-libs/mongo-c-driver] add a test-full useflag to mask on non-mongodb arches
This commit is contained in:
parent
45aadb32ea
commit
9cf87dd318
@ -5,6 +5,12 @@
|
|||||||
<email>ultrabug@gentoo.org</email>
|
<email>ultrabug@gentoo.org</email>
|
||||||
<name>Alexys Jacob</name>
|
<name>Alexys Jacob</name>
|
||||||
</maintainer>
|
</maintainer>
|
||||||
|
<use>
|
||||||
|
<flag name="test-full">
|
||||||
|
Run test suite in full, including tests that run a local
|
||||||
|
database instance.
|
||||||
|
</flag>
|
||||||
|
</use>
|
||||||
<upstream>
|
<upstream>
|
||||||
<remote-id type="github">mongodb/mongo-c-driver</remote-id>
|
<remote-id type="github">mongodb/mongo-c-driver</remote-id>
|
||||||
</upstream>
|
</upstream>
|
||||||
|
@ -12,7 +12,7 @@ SRC_URI="https://github.com/mongodb/mongo-c-driver/archive/refs/tags/${PV}.tar.g
|
|||||||
LICENSE="Apache-2.0"
|
LICENSE="Apache-2.0"
|
||||||
SLOT="0"
|
SLOT="0"
|
||||||
KEYWORDS="~amd64 ~arm64 ~hppa ~riscv ~x86"
|
KEYWORDS="~amd64 ~arm64 ~hppa ~riscv ~x86"
|
||||||
IUSE="debug examples icu +s3 sasl +ssl static-libs test"
|
IUSE="debug examples icu +s3 sasl +ssl static-libs test +test-full"
|
||||||
REQUIRED_USE="
|
REQUIRED_USE="
|
||||||
s3? ( ssl )
|
s3? ( ssl )
|
||||||
test? ( static-libs )"
|
test? ( static-libs )"
|
||||||
@ -36,10 +36,12 @@ RDEPEND="
|
|||||||
DEPEND="
|
DEPEND="
|
||||||
${RDEPEND}
|
${RDEPEND}
|
||||||
test? (
|
test? (
|
||||||
dev-db/mongodb
|
|
||||||
dev-libs/libbson[static-libs]
|
dev-libs/libbson[static-libs]
|
||||||
>=dev-libs/libmongocrypt-1.10.0[static-libs]
|
>=dev-libs/libmongocrypt-1.10.0[static-libs]
|
||||||
>=dev-libs/libutf8proc-2.8.0:=[static-libs]
|
>=dev-libs/libutf8proc-2.8.0:=[static-libs]
|
||||||
|
test-full? (
|
||||||
|
dev-db/mongodb
|
||||||
|
)
|
||||||
)
|
)
|
||||||
"
|
"
|
||||||
|
|
||||||
@ -89,14 +91,19 @@ src_configure() {
|
|||||||
|
|
||||||
# FEATURES="test -network-sandbox" USE="static-libs" emerge dev-libs/mongo-c-driver
|
# FEATURES="test -network-sandbox" USE="static-libs" emerge dev-libs/mongo-c-driver
|
||||||
src_test() {
|
src_test() {
|
||||||
|
if ! use test-full; then
|
||||||
|
export MONGOC_TEST_SKIP_LIVE=on
|
||||||
|
else
|
||||||
local PORT=27099
|
local PORT=27099
|
||||||
|
export MONGOC_TEST_URI="mongodb://[127.0.0.1]:${PORT}"
|
||||||
|
export MONGOC_ENABLE_MAJORITY_READ_CONCERN=on
|
||||||
LC_ALL=C \
|
LC_ALL=C \
|
||||||
mongod --setParameter enableTestCommands=1 \
|
mongod --setParameter enableTestCommands=1 \
|
||||||
--enableMajorityReadConcern --port ${PORT} \
|
--enableMajorityReadConcern --port ${PORT} \
|
||||||
--bind_ip 127.0.0.1 --nounixsocket --fork --dbpath="${T}" \
|
--bind_ip 127.0.0.1 --nounixsocket --fork \
|
||||||
--logpath="${T}/mongod.log" || die
|
--dbpath="${T}" --logpath="${T}/mongod.log" || die
|
||||||
MONGOC_TEST_URI="mongodb://[127.0.0.1]:${PORT}" \
|
fi
|
||||||
MONGOC_ENABLE_MAJORITY_READ_CONCERN=on \
|
|
||||||
../mongo-c-driver-${PV}_build/src/libmongoc/test-libmongoc \
|
../mongo-c-driver-${PV}_build/src/libmongoc/test-libmongoc \
|
||||||
--skip-tests "${FILESDIR}/skip-tests.txt" || die
|
--skip-tests "${FILESDIR}/skip-tests.txt" || die
|
||||||
kill $(<"${T}/mongod.lock")
|
kill $(<"${T}/mongod.lock")
|
||||||
|
Loading…
Reference in New Issue
Block a user