diff options
author | Michał Górny <mgorny@gentoo.org> | 2022-11-06 15:03:59 +0100 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2022-11-06 15:06:27 +0100 |
commit | 31950d58c54ab9c23f1b5487ab9db2d0b3c5aaec (patch) | |
tree | b57598545be06de0c2098e83ce25f16715675325 /dev-python/qiskit-terra | |
parent | dev-python/qiskit-terra: Fix rustworkx support (diff) | |
download | gentoo-31950d58c54ab9c23f1b5487ab9db2d0b3c5aaec.tar.gz gentoo-31950d58c54ab9c23f1b5487ab9db2d0b3c5aaec.tar.bz2 gentoo-31950d58c54ab9c23f1b5487ab9db2d0b3c5aaec.zip |
dev-python/qiskit-terra: Use EPYTEST_*, fix tests
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python/qiskit-terra')
-rw-r--r-- | dev-python/qiskit-terra/qiskit-terra-0.22.0-r1.ebuild | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/dev-python/qiskit-terra/qiskit-terra-0.22.0-r1.ebuild b/dev-python/qiskit-terra/qiskit-terra-0.22.0-r1.ebuild index fd442eceacd3..b25eb56cf16e 100644 --- a/dev-python/qiskit-terra/qiskit-terra-0.22.0-r1.ebuild +++ b/dev-python/qiskit-terra/qiskit-terra-0.22.0-r1.ebuild @@ -123,25 +123,22 @@ BDEPEND=" distutils_enable_tests pytest -# Small issues with the tests. -# qiskit.Aer module depends on qiskit-terra, it cannot be used, -# and an exact comparison of float switched to approximate comparison. -#PATCHES=( "${FILESDIR}/qiskit-terra-0.19.2-test-corrections.patch" ) - src_prepare() { find -name '*.py' -exec sed -i -e 's:retworkx:rustworkx:' {} + || die distutils-r1_src_prepare } python_test() { - # We have to hide the source code directory so tests - # do not use these, but instead the compiled library. - mv qiskit qiskit.hidden || die - - # Some small tests are failing which test optional features. - # Why they fail is still under investigation. - # transpiler_equivalence tests take too long time, they are also skipped. - epytest -n "$(makeopts_jobs)" -k 'not (TestOptions and test_copy) and not TestUnitarySynthesisPlugin and not test_transpiler_equivalence and not (TestPauliSumOp and test_to_instruction)' + local EPYTEST_DESELECT=( + # TODO + test/python/transpiler/test_unitary_synthesis_plugin.py::TestUnitarySynthesisPlugin + test/python/transpiler/test_unitary_synthesis.py::TestUnitarySynthesis::test_two_qubit_synthesis_not_pulse_optimal + ) + local EPYTEST_IGNORE=( + # TODO, also apparently slow + test/randomized/test_transpiler_equivalence.py + ) - mv qiskit.hidden qiskit || die + rm -rf qiskit || die + epytest -p xdist -n "$(makeopts_jobs)" } |