summaryrefslogtreecommitdiff
path: root/numpy/distutils/tests
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #22493 from mwtoews/maint-openSebastian Berg2023-04-281-2/+2
|\ | | | | MAINT: remove redundant open() modes and io.open() alias
| * MAINT: remove redundant open() modes and io.open() aliasMike Taves2022-10-291-2/+2
| |
* | ENH: add support for fujitsu C/C++ compiler and SSL2 to numpy.yamadafuyuka2023-03-021-3/+3
| |
* | TST: Skip tests that are not currently supported in wasmHood Chatham2022-11-113-1/+9
|/
* STY: Make linter happySebastian Berg2022-10-271-1/+0
| | | | Not new things, but in touched lines...
* TST: Try using setup_class for `_Test_CCompilerOpt`Sebastian Berg2022-10-271-2/+2
|
* TST,MAINT: Replace most `setup` with `setup_method` (also teardown)Sebastian Berg2022-10-273-5/+5
| | | | | | | | 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)
* TST: Remove most prints from the test suit runSebastian Berg2022-05-051-1/+3
| | | | | | | | Pytest silence these normally anyway (capturing it to print it only on failure), but occasionally I run with `-s` and I don't think this output adds anything unless using printing to debug a specific test. If nobody else cares about it nvm, just close it :). Otherwise this cleans up everything in the fast tests, except the f2py compilation right now.
* TST: Add CPU dispatch/baseline tests for VSX4Rafael Cardoso Fernandes Sousa2022-01-171-5/+5
|
* ENH: Add CPU feature detection for VSX4 (Power10)Rafael Cardoso Fernandes Sousa2022-01-131-1/+1
|
* BUG, DIST: fix normalize IBMZ features flagsSayed Adel2021-12-151-1/+5
| | | | | | | | | | | | | | | | | | | | | | The normal behavior is to erase any flag that starts with `-m[a-z0-9\-\.]` when flag `-march` or `-mcpu` specified. for example: cc_normalize_flags([ '-msse', '-msse2', '-msse3', '-mssse3', '-march=core-avx2' ]) should be normalized to: ['-march=core-avx2'] but in the case of `s390x`, on GCC flag `-march=arch[0-9]` doesn't implies flag `-mzvector` which is required to enable zvector api. for example: cc_normalize_flags([ '-mzvector', '-march=arch11', '-march=arch12', '-march=arch13'] ) should be normalized to: ['-mzvector', '-march=arch13'] instead of: ['-march=arch13']
* TST: expend ccompiler tests to cover s390x featuresSayed Adel2021-12-141-30/+45
|
* ENH: add log level as prefixes to respective messagesMatthew2021-11-121-0/+32
|
* BUG: Don't pass /arch:SSE2 to MSVC when targeting x64 (#20190)Tom Tan2021-10-251-2/+4
| | | | | | | | | * Don't pass /arch:SSE2 to MSVC link targeting x64 * Fix test * Fix format * Fix one more test
* TST: xfail `test_overrides` when numpy is build with MKL supportBas van Beek2021-10-231-0/+4
|
* MAINT: Python3 classes do not need to inherit from objectMike Taves2021-05-191-1/+1
|
* BUG: Fix test_ccompiler_opt when path contains dotsMichał Górny2021-03-281-1/+1
| | | | | | | | | | | | | | Fix test_ccompiler_opt not to be confused by dots occurring on the path to the temporary directory, by using only the source file's basename when grabbing options. Otherwise, the test can fail with mismatches such as: E AssertionError: 'sources_status' returns different targets than the compiled targets E ['AVX512F', 'AVX2'] != ['(20 2/TEMP/TMPB0YHSCAI/TEST_TARGETS AVX512F)', '(20 2/TEMP/TMPB0YHSCAI/TEST_TARGETS AVX2)'] This is because our TMPDIR value includes numpy version, i.e. 1.20.2. The splitting happens on the first dot that is part of the directory path rather than test filename.
* BUG: don't mutate list of fake libraries while iterating over it (#18295)Nicholas McKibben2021-02-041-0/+72
| | | | | | | | | | | | | | | | | * BUG: don't mutate list of fake libraries while iterating over it * BUG: iterate over copy of list * TST: add build test for build_ext fix (#1) * TST: add build test for build_ext fix * TST: clearer test name * STY: use triple quotes instead of lists of strings * FIX: check for f77 compiler before test is run * DOC: add comment explaining that a list copy is necessary
* TST: Avoid changing odd tempfile names in tests' site.cfgDWesl2021-01-011-2/+2
| | | | | | | | CI once produced a tempfile name with the string 'mkl' embedded. The old code changed this as well as the section name. This should ensure only section names get changed, and the restriction on the number of replacements should catch any weird corner cases, since I think the sections came first.
* BLD, BUG: Fix detecting aarch64 on macOSSayed Adel2020-12-202-3/+3
| | | | Co-authored-by: h-vetinari <h.vetinari@gmx.com>
* TST: Expanded the `_parse_env_order` testsBas van Beek2020-09-181-1/+7
| | | | | | Relevant for when LAPACK/BLAS optimization is disabled. Addresses https://github.com/numpy/numpy/pull/17346#issuecomment-694744389.
* BLD: enabled negation of library choices in NPY_*_ORDER (#17219)Nick R. Papior2020-09-171-0/+27
| | | | | | | | | | | | | | | | | | | | | | | BLD: enabled negation of library choices in NPY_*_ORDER When users build for a particular order it may be beneficial to disallow certain libraries. In particular a user may not care about which accelerated BLAS library is used, so long as the NetLIB or ATLAS library isn't used. This is now possible with: NPY_BLAS_ORDER='^blas,atlas' or NPY_BLAS_ORDER='!blas,atlas' Since we may envision more BLAS/LAPACK libraries to the pool, this will provide greater flexibility as they enter. A new (local) method is added in system_info.py which removes duplicate code and allows for easier usage across libraries.
* TST: remove unnecessary backslashes from CCompilerOpt config testSayed Adel2020-08-261-24/+12
| | | | | | Also fix assertion error msg of group/extra_checks Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
* BLD: Check for reduce intrinsics and AVX512BW mask operationsSayed Adel2020-08-261-2/+21
| | | | | | | | - Extending Distutils::CompilerOpt to allow adding extra separate test cases related to a certain CPU feature without affecting its availability. - Add test cases for reduce intrinsics and AVX512BW mask operations, they can be reached through C #defentions NPY_HAVE_AVX512BW_MASK and NPY_HAVE_AVX512F_REDUCE.
* ENH: [2/7] enable multi-platform SIMD compiler optimizationsSayed Adel2020-06-152-0/+956
| | | | Add testing unit for `CCompilerOpt`
* BUG: fix logic error when nm fails on 32-bitmattip2020-03-081-4/+7
|
* MAINT: use list-based APIs to call subprocesses (#15714)Sebastian Berg2020-03-071-0/+39
| | | | | | * MAINT: use list-based APIs to call subprocesses * TST, MAINT: add a test for mingw32ccompiler.build_import, clean up lib2def Co-authored-by: Matti Picus <matti.picus@gmail.com> Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
* MAINT: cleanup unused imports; avoid redefinition of importsMike Taves2020-02-062-4/+1
| | | | | | | * 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)
* Merge pull request #15338 from mattip/site.cfgCharles Harris2020-01-311-1/+33
|\ | | | | DOC: document site.cfg.example
| * DOC: link and cleanup docstrings in site.cfg.examplemattip2020-01-201-1/+33
| |
* | STY: use `with open` when possibleSeth Troisi2020-01-211-3/+2
|/
* MAINT: Remove sys.version checks in testsSeth Troisi2020-01-151-4/+1
|
* Merge pull request #15238 from mattip/redo-c99Charles Harris2020-01-051-22/+0
|\ | | | | MAINT: only add --std=c99 where needed
| * MAINT: add --std=c99 in setup.py, not distutilsmattip2020-01-051-22/+0
| |
* | MAINT: Remove implicit inheritance from object class (#15236)Jon Dufresne2020-01-057-16/+16
|/ | | | | | | Inheriting from object was necessary for Python 2 compatibility to use new-style classes. In Python 3, this is unnecessary as there are no old-style classes. Dropping the object is more idiomatic Python.
* MAINT: Remove unnecessary 'from __future__ import ...' statementsJon Dufresne2020-01-0310-20/+0
| | | | | As numpy is Python 3 only, these import statements are now unnecessary and don't alter runtime behavior.
* BUG: remove -std=c99 for c++ compilation (#15194)Matti Picus2019-12-301-0/+24
| | | This flag is only legal for C compilers
* BLD: MAINT: change default behavior of build flag appending.Ralf Gommers2019-08-201-34/+0
| | | | | | This is a follow-up to gh-7427. This can lead to hard to understand build failures, and we've warned that this change was coming for two releases.
* BLD: streamlined library names in site.cfg sections (#13157)Nick R. Papior2019-04-301-2/+22
| | | * BLD: use libraries as a key consistently in all site.cfg sections
* DEP: deprecate exec_commandmattip2019-03-101-13/+18
|
* Merge pull request #12925 from eric-wieser/distutils-shlex-splitCharles Harris2019-02-251-4/+6
|\ | | | | BUG: parse shell escaping in extra_compile_args and extra_link_args
| * BUG: parse shell escaping in extra_compile_args and extra_link_argsEric Wieser2019-02-241-4/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Thanks to a change in exec_command, these strings are no longer passed onto the shell. Since config files do not support list values, our best bet is to perform shell-splitting immediately. This brings the behavior back in line a little to how it was before. On windows systems, the behavior has changed. Previously it was treated as a single argument unless it contained quotes, resulting in the following weird behavior: # passes as one argument, preserving spaces extra_link_args=-Wl,rpath=A:/path/with spaces # passes as two arguments, preserving spaces extra_link_args="-Wl,rpath=A:\path\with spaces" -lgfortran # passes as one long quoted argument (surprising and undesirable) extra_link_args=-Wl,rpath=A:\path\without_spaces -lgfortran Now it behaves as windows escaping via subprocess (but _not_ via cmd) normally would: # Passed as two separate arguments (probably not as intended, but should be expected) extra_link_args=-Wl,rpath=A:/path/with spaces # passes as two arguments, preserving spaces extra_link_args="-Wl,rpath=A:\path\with spaces" -lgfortran # passes as two arguments extra_link_args=-Wl,rpath=A:\path\without_spaces -lgfortran Fixes gh-12659
* | Merge pull request #13023 from eric-wieser/distutils-windows-splitCharles Harris2019-02-241-0/+79
|\ \ | |/ | | BUG: Changes to string-to-shell parsing behavior broke paths with quotes
| * MAINT: Add functions to parse shell-strings in the platform-native wayEric Wieser2019-02-231-0/+79
| | | | | | | | | | | | | | | | | | | | There are places in distutils where we accept a single string from the user, and interpret it as a set of command line arguments. Previously, these were passed on as a string unmodified to exec_command, and interpreted by subprocess in a platform-specific way. Recent changes to distutils now pass a list of arguments to subprocess, meaning we have to split the strings ourselves. While `shlex.split` is perfect on posix systems, it is not a good approximation of either the old or the expected behavior on windows. Provides the building blocks needed to fix gh-12979
* | TST: suppress test warnings for appending flag behavior better.Ralf Gommers2018-12-271-3/+8
| |
* | MAINT: add warning to numpy.distutils for LDFLAGS append behavior.Ralf Gommers2018-12-271-2/+34
| | | | | | | | See gh-7427
* | MAINT: Review F401,F841,F842 flake8 errors (unused variables and imports) ↵Roman Yurchak2018-12-061-0/+3
|/ | | | | | | | | | | | (#12448) * Review F401,F841,F842 flake8 errors (unused variables, imports) * Review comments * More tests in test_installed_npymath_ini * Review comments
* Remove redundant codeIsuru Fernando2018-07-071-2/+0
|
* Use monkeypatch's setenv, getenvIsuru Fernando2018-07-071-8/+7
|
* Test distutils flags appendingIsuru Fernando2018-07-071-0/+47
|