X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=test%2FT391-python-cffi.sh;h=0ef9e0d3c0604ca5f86f2d59180a85cd0c977a65;hb=f6fcdf12da455d82a9ed0a0a33eddac60253a6e8;hp=e4f80dc6544a33483a843c961ca541f5217bd366;hpb=85adc756c97646ae63e68fc2f80afd6b34b86fa9;p=notmuch diff --git a/test/T391-python-cffi.sh b/test/T391-python-cffi.sh index e4f80dc6..0ef9e0d3 100755 --- a/test/T391-python-cffi.sh +++ b/test/T391-python-cffi.sh @@ -2,13 +2,18 @@ test_description="python bindings (pytest)" . $(dirname "$0")/test-lib.sh || exit 1 -if [ $NOTMUCH_HAVE_PYTHON3_CFFI -eq 0 -o $NOTMUCH_HAVE_PYTHON3_PYTEST -eq 0 ]; then +if [ "${NOTMUCH_HAVE_PYTHON3_CFFI-0}" = "0" -o "${NOTMUCH_HAVE_PYTHON3_PYTEST-0}" = "0" ]; then test_done fi +test_begin_subtest "python cffi tests (NOTMUCH_CONFIG set)" +pytest_dir=$NOTMUCH_BUILDDIR/bindings/python-cffi/build/stage +printf "[pytest]\nminversion = 3.0\naddopts = -ra\n" > $pytest_dir/pytest.ini +test_expect_success "(cd $pytest_dir && ${NOTMUCH_PYTHON} -m pytest --verbose --log-file=$TMP_DIRECTORY/test.output)" -test_begin_subtest "python cffi tests" -pytest_dir=$NOTMUCH_SRCDIR/bindings/python-cffi/build/stage +test_begin_subtest "python cffi tests (NOTMUCH_CONFIG unset)" +pytest_dir=$NOTMUCH_BUILDDIR/bindings/python-cffi/build/stage printf "[pytest]\nminversion = 3.0\naddopts = -ra\n" > $pytest_dir/pytest.ini -test_expect_success "(cd $pytest_dir && ${NOTMUCH_PYTHON} -m pytest --log-file=$TMP_DIRECTORY/test.output)" +unset NOTMUCH_CONFIG +test_expect_success "(cd $pytest_dir && ${NOTMUCH_PYTHON} -m pytest --verbose --log-file=$TMP_DIRECTORY/test.output)" test_done