summaryrefslogtreecommitdiff
path: root/numpy/random/tests/test_extending.py
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #22713 from seberg/numba-systemerrorCharles Harris2022-12-021-1/+2
|\ | | | | TST: Skip when numba/numpy compat issues cause SystemError
| * TST: Skip when numba/numpy compat issues cause SystemErrorSebastian Berg2022-12-021-1/+2
| | | | | | | | | | | | | | | | numba is a bit buggy when wrapping ufuncs, so what should be nothing is (on non dev versions) a SystemError and not even an ImportError. So simply catch those too, since it can be a confusing error during dev otherwise.
* | MAINT: Move _inspect and _pep440 from compat to _utilsSebastian Berg2022-11-251-1/+1
|/ | | | | Note that unfortunately, compat does expose _inspect as well, so the import remains (just the definition place moves).
* TST: Skip tests that are not currently supported in wasmHood Chatham2022-11-111-0/+3
|
* Tests/Docs: Update tests to Cython 0.29.30, mention in docsEwout ter Hoeven2022-05-201-2/+2
| | | | | | Cython 0.29.30 is required for building Numpy with Python 3.11. This commit updates that in the core/tests/test_cython.py and random/tests/test_exending.py files. It also mentions that Cython 0.29.30 is needed in the INSTALL documentation.
* MAINT: Replace LooseVersion by _pep440.Charles Harris2022-02-051-4/+4
| | | | | | | | LooseVersion is provided by Python distutils, which is going away in 3.12. This PR vendors _pep440 from scipy and uses it as a replacement. Numpy distutils is not touched, replacing LooseVersion in that package was considered too risky, and numpy distutils will need to go away when Python distutils does.
* ENH: provide a convenience function to replace npy_load_module (#20395)Matti Picus2021-11-191-4/+4
| | | | | | | `load_module` is deprecated since python 3.4 and will be removed in python 3.12. Use `exec_module` instead. Provide a convenience function in `distutils.misc_utils` instead of `npy_load_module` from `compat.py3k`.
* BLD: update cython to 0.29.21mattip2020-07-101-2/+2
|
* TST: add tag to __init__.pxd and test that the tag is foundmattip2020-05-061-3/+13
|
* BUG: add missing c_distributions.pxd, enables cython use of random C-API ↵Matti Picus2020-03-161-4/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (gh-15463) xref gh-14778 As pointed out in the comment by @jamesthomasgriffin, we did not include a pxd file to expose the distribution functions documented in the random c-api. This PR adds a c_distributions.pxd file that exposes them. Squashed commits: * BUG: add missing c_distributions.pxd to enable cython use of random C-API * ENH, TST: add npyrandom library like npymath, test cython use of it * BUG: actually prefix f-string with f * MAINT: fixes from review, add _bit_generato_bit_generator.pxd * STY: fixes from review * BLD: don't use nprandom library for mtrand legacy build * TST: WindowsPath cannot be used in subprocess's list2cmdline * MAINT, API: move _bit_generator to bit_generator * DOC: add release note about moving bit_generator * DOC, MAINT: fixes from review * MAINT: redo dtype determination from review
* MAINT: cleanup unused imports; avoid redefinition of importsMike Taves2020-02-061-2/+2
| | | | | | | * Cleanup unused imports (F401) of mostly standard Python modules, or some internal but unlikely referenced modules * Where internal imports are potentially used, mark with noqa * Avoid redefinition of imports (F811)
* STY,MAINT: avoid 'multiple imports on one line' (flake8 E401)Mike Taves2020-01-281-2/+3
| | | | | | * PEP 8: "Imports should usually be on separate lines" * Where modified, sort imported modules alphabetically * Clean-up unused imports from these expanded lines
* MAINT: remove dead code from reviewmattip2019-12-271-1/+0
|
* MAINT: unskip test on win32mattip2019-12-271-1/+0
|
* BUG: use tmp dir and check version for cython test (#15170)Matti Picus2019-12-261-16/+23
| | | | | | | | | | | | * BUG: use tmp dir and check version for cython test * TST, MAINT: skip on win32, fix formatting * TST: fixes from review * TST: fixes from review * TST: fixes from review
* Merge pull request #14954 from mattip/test-extending-cffiCharles Harris2019-11-271-2/+15
|\ | | | | TST. API: test using distributions.h via cffi
| * TST: skip cffi tests when PYTHONOPTIMIZE>1, pycparser failsmattip2019-11-211-0/+5
| |
| * TST. API: test using distributions.h via cffimattip2019-11-211-2/+10
| |
* | TST: skip if cython is not availablemattip2019-11-221-0/+6
|/
* MAINT: move numpy/random/examples -> numpy/random/_examplesmattip2019-11-191-3/+3
|
* API: restructure and document numpy.random C-API (#14604)Matti Picus2019-11-191-0/+32
* API: restructure and document numpy.random C-API * DOC: fix bad reference * API: ship, document, and start to test numpy.random C-API examples * API, DOC, TST: fix tests, refactor documentation to include snippets * BUILD: move public headers to numpy/core/include/numpy/random * TST: ignore DeprecationWarnings in setuptools and numba * DOC: document the C-API as used from Cython