From 3c3127dcf80739f858064cc199b4bf000a741ac2 Mon Sep 17 00:00:00 2001 From: Yuri Victorovich Date: Fri, 21 Oct 2022 06:09:55 -0800 Subject: [PATCH] math/py-rustworkx: Add tests --- .../patch-src_IVtkDraw_IVtkDraw__Interactor.cxx | 17 +++++++++++++++++ math/py-rustworkx/Makefile | 6 +++++- 2 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 cad/opencascade/files/patch-src_IVtkDraw_IVtkDraw__Interactor.cxx diff --git a/cad/opencascade/files/patch-src_IVtkDraw_IVtkDraw__Interactor.cxx b/cad/opencascade/files/patch-src_IVtkDraw_IVtkDraw__Interactor.cxx new file mode 100644 index 000000000000..e5b6146f4111 --- /dev/null +++ b/cad/opencascade/files/patch-src_IVtkDraw_IVtkDraw__Interactor.cxx @@ -0,0 +1,17 @@ +- workaround for https://gitlab.kitware.com/vtk/vtk/-/issues/18683 + +--- src/IVtkDraw/IVtkDraw_Interactor.cxx.orig 2021-10-30 11:13:52 UTC ++++ src/IVtkDraw/IVtkDraw_Interactor.cxx +@@ -26,6 +26,12 @@ + #ifdef AllValues + #undef AllValues + #endif ++#ifdef Status ++#undef Status ++#endif ++#ifdef Success ++#undef Success ++#endif + + #include + #include diff --git a/math/py-rustworkx/Makefile b/math/py-rustworkx/Makefile index b36d9d2875ee..c59fc439316f 100644 --- a/math/py-rustworkx/Makefile +++ b/math/py-rustworkx/Makefile @@ -13,9 +13,10 @@ LICENSE_FILE= ${WRKSRC}/LICENSE BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}setuptools-rust>0:devel/py-setuptools-rust@${PY_FLAVOR} RUN_DEPENDS= ${PYNUMPY} +TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}tox>0:devel/py-tox@${PY_FLAVOR} USES= cargo python:3.7+ -USE_PYTHON= autoplist distutils pytest # unclear how to run tests, see https://github.com/Qiskit/rustworkx/issues/695 +USE_PYTHON= autoplist distutils USE_GITHUB= yes GH_ACCOUNT= Qiskit @@ -105,4 +106,7 @@ BINARY_ALIAS= python3=${PYTHON_CMD} post-install: @${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/rustworkx/rustworkx.cpython-${PYTHON_SUFFIX}.so +do-test: + @cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} tox -epy + .include