summaryrefslogtreecommitdiff
path: root/numpy/testing
Commit message (Collapse)AuthorAgeFilesLines
* DOC: fix incorrect description of raise condition in ↵Clément Robert2023-05-051-1/+1
| | | | numpy.testing.assert_array_less's docstring
* MAINT: Remove gisnan, gisinf, and gisfinite from testing codeSebastian Berg2023-05-031-68/+13
| | | | | | | | | | | These were introduced many years ago when ufuncs were buggy and could return NotImplemented sometimes. This has been fixed for many years, though. I suspect the errstate for `isfinite` is not required so removed it. It was a 12+ year old work-around for warnings that really shouldn't happen to begin with. (The commit mentions `np.isinf(np.inf)` giving a warning, which doesn't make sense, I think.)
* Merge pull request #22493 from mwtoews/maint-openSebastian Berg2023-04-281-3/+3
|\ | | | | MAINT: remove redundant open() modes and io.open() alias
| * MAINT: remove redundant open() modes and io.open() aliasMike Taves2022-10-291-3/+3
| |
* | MAINT: remove `NUMPY_EXPERIMENTAL_ARRAY_FUNCTION` env varRalf Gommers2023-03-121-3/+0
| | | | | | | | | | | | | | | | As discussed in https://mail.python.org/archives/list/numpy-discussion@python.org/thread/UKZJACAP5FUG7KP2AQDPE4P5ADNWLOHZ/ This flag was always meant to be temporary, and cleaning it up is long overdue.
* | Merge pull request #22982 from yamadafuyuka/add_fujitsuccompiler_and_SSL2Sebastian Berg2023-03-061-1/+18
|\ \ | | | | | | ENH: add support for fujitsu C/C++ compiler and SSL2 to numpy.
| * | ENH: add support for fujitsu C/C++ compiler and SSL2 to numpy.yamadafuyuka2023-03-021-1/+18
| | |
* | | DOC: Fix code formattingyuki2023-02-241-1/+1
| | |
* | | DOC: Fix wrong section titleyuki2023-02-241-2/+2
| | |
* | | MAINT: testing: Fix some whitespace and minor code issues in utils.pywarren2023-02-161-17/+18
|/ /
* | MAINT: fix typo in overrides.pyIkko Eltociear Ashimine2023-02-101-2/+2
| | | | | | overriden -> overridden
* | DEP: Remove the deprecated utils.py shim.Charles Harris2023-01-211-29/+0
| | | | | | | | | | The shim has been deprecated since 2019, the proper place to import utils funtions is directly from numpy.testing.
* | CI: musllinux_x86_64 (#22864)Andrew Nelson2023-01-201-1/+15
| | | | | | [ci skip]
* | MAINT: Remove all nose testing support.Charles Harris2023-01-199-1836/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | NumPy switched to using pytest in 2018 and nose has been unmaintained for many years. We have kept NumPy's nose support to avoid breaking downstream projects who might have been using it and not yet switched to pytest or some other testing framework. With the arrival of Python 3.12, unpatched nose will raise an error. It it time to move on. Decorators removed - raises - slow - setastest - skipif - knownfailif - deprecated - parametrize - _needs_refcount These are not to be confused with pytest versions with similar names, e.g., pytest.mark.slow, pytest.mark.skipif, pytest.mark.parametrize. Functions removed - Tester - import_nose - run_module_suite
* | DOC: Add version added information for the strict parameter in ↵Mark Harfouche2023-01-151-0/+2
| | | | | | | | assert_array_equal (#23015)
* | BUG: Fixes for numpy.testing.overrides (#22879)Nathan Goldbaum2023-01-022-1/+5
| | | | | | Followup for gh-22533. Adds a missing return statement to get_overridable_numpy_ufuncs (oops!) and imports numpy.testing.overrides into numpy.testing so e.g. tab completion on numpy.testing works for overrides.
* | Merge pull request #22533 from ngoldbaum/ufunc-and-function-listingSebastian Berg2022-11-291-0/+82
|\ \ | | | | | | API: Add numpy.testing.overrides to aid testing of custom array containers
| * | API: Add numpy.testing.overrides to aid testing of custom array containersNathan Goldbaum2022-11-161-0/+82
| |/ | | | | | | Closes #15544
* | DOC: testing: Fix typo: nulps -> nulpwarren2022-11-181-1/+1
| | | | | | | | [skip actions] [skip travis] [skip azp]
* | TST: Skip tests that are not currently supported in wasmHood Chatham2022-11-111-1/+2
|/
* TST,MAINT: Replace most `setup` with `setup_method` (also teardown)Sebastian Berg2022-10-271-7/+7
| | | | | | | | In some cases, the replacement is clearly not what is intended, in those (where setup was called explicitly), I mostly renamed `setup` to `_setup`. The `test_ccompile_opt` is a bit confusing, so left it right now (this will probably fail)
* PERF: Eliminate slow check for pypy during numpy import (#22163)Pieter Eendebak2022-08-231-1/+1
| | | | | | | This PR replaces the import of platform and a call to platform.python_implementation() with a check using sys.implementation.name to improve the numpy import time. The improvement is about 5-10 ms (system dependent). Also see #22061 Co-authored-by: Matti Picus <matti.picus@gmail.com>
* ENH: allow importlib.LazyLoader to work with numpy and add test of this (#22045)Dan Schult2022-07-271-0/+1
|
* ENH: reorder includes for system installationsmattip2022-07-201-1/+1
|
* Merge pull request #21795 from hmaarrfk/no_overflow_unsignedSebastian Berg2022-07-062-0/+17
|\ | | | | ENH: Ensure that assertion of unsigned dtypes does not return results
| * BUG: Ensure that assertion of unsigned dtypes does not return resultsMark Harfouche2022-06-291-0/+3
| | | | | | | | that wrapped around.
| * TST: Add a failing test case to demonstrate the bug gh2176Mark Harfouche2022-06-291-0/+14
| |
* | Merge pull request #21626 from seberg/weak-scalarsCharles Harris2022-06-261-2/+9
|\ \ | | | | | | API: Introduce optional (and partial) NEP 50 weak scalar logic
| * | TST: Improve testing setup by introducing a new `weak_promotion` fixtureSebastian Berg2022-06-151-2/+2
| | | | | | | | | | | | Unfortunately, this shows that the rational tests are still broken a bit.
| * | API: Add leading underscore to `no_nep50_warning` and `get/set_promotion_state`Sebastian Berg2022-06-151-5/+5
| | |
| * | API: Enforce float64 precision for `assert_almost_equal`Sebastian Berg2022-06-151-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | This ensures that the precision is not downcast, which could make a small value zero (for float16 mostly). This lets tests pass that check whether `np.float16(0)` is almost equal to 0, which otherwise fail (because `float16(0.00000001)` will evaluate to 0 exactly.
| * | TST: Make test compatible with new promotion or mark for no-warningsSebastian Berg2022-06-151-0/+3
| | |
| * | WIP: Add warning context manager and fix min_scalar for new promotionSebastian Berg2022-06-151-0/+4
| |/ | | | | | | | | Even the new promotion has to use the min-scalar logic to avoid picking up a float16 loop for `np.int8(3) * 3.`.
* | ENH: Add strict parameter to assert_array_equal. (#21595)Jon Morris2022-06-243-6/+87
|/ | | | | | Fixes #9542 Co-authored-by: Bas van Beek <43369155+BvB93@users.noreply.github.com>
* Merge pull request #21579 from sachu92/doc-assert_allcloseCharles Harris2022-06-071-0/+12
|\ | | | | DOC: Improve docstring of numpy.testing.assert_allclose
| * MAINT: Small rewrite for clarity.Charles Harris2022-06-071-6/+5
| |
| * STY: Use single backticks around parameter names.Charles Harris2022-06-071-1/+1
| |
| * Break lines in comments to follow line length limitsSachin Krishnan T V2022-05-231-3/+3
| |
| * Make double backticks for parameters in docstringSachin Krishnan T V2022-05-231-1/+1
| |
| * Improve docstring of numpy.testing.assert_allcloseSachin Krishnan T V2022-05-231-0/+13
| |
* | MAINT: revert changes, so all tests pass for warning contextsBrigitta Sipőcz2022-05-231-14/+7
| |
* | MAINT: Fix warningc context tests, uncover bug?Brigitta Sipőcz2022-05-231-6/+20
| |
* | MAINT: Python <3.8 related cleanupsBrigitta Sipőcz2022-05-231-11/+9
| |
* | MAINT: Python <3.7 related cleanupsBrigitta Sipőcz2022-05-231-7/+0
|/
* Merge pull request #19226 from ↵Matti Picus2022-05-191-4/+3
|\ | | | | | | | | seberg/fix-void-cast-safety-promotion-and-comparison API: Fix structured dtype cast-safety, promotion, and comparison
| * API: Fix structured dtype cast-safety, promotion, and comparisonSebastian Berg2022-05-091-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This PR replaces the old gh-15509 implementing proper type promotion for structured voids. It further fixes the casting safety to consider casts with equivalent field number and matching order as "safe" and if the names, titles, and offsets match as "equiv". The change perculates into the void comparison, and since it fixes the order, it removes the current FutureWarning there as well. This addresses https://github.com/liberfa/pyerfa/issues/77 and replaces gh-15509 (the implementation has changed too much). Fixes gh-15494 (and probably a few more) Co-authored-by: Allan Haldane <allan.haldane@gmail.com>
* | Remove python <3.6 related thingsBrigitta Sipocz2022-05-172-14/+5
|/
* MAINT: Split `numpy.typing` into a public and private componentBas van Beek2022-03-181-1/+1
| | | | i.e. `numpy.typing` and `numpy._typing`
* ENH: Suppress over-/underflow RuntimeWarning in assert_array_equal (#21003)Simon Surland Andersen2022-02-082-1/+9
| | | | | | | | | | | * TST: Test suppression of asset_array_equal RuntimeWarning See #18992 * ENH: Suppress over-/underflow warnings on asset_array_equal - Closes #18992 * MAINT: Resolve linting issues of prior commit * MAINT: Simplified ignore and test case of asset_array_equal * MAINT: Removed unused import in test_utils.py
* Merge pull request #20885 from BvB93/param_specCharles Harris2022-01-241-15/+17
|\ | | | | TYP,ENH: Improve typing with the help of `ParamSpec`