Mathics3 / mathics-core

An open-source Mathematica. This repository contains the Python modules for WL Built-in functions, variables, core primitives, e.g. Symbol, a parser to create Expressions, and an evaluator to execute them.
https://mathics.org
Other
786 stars 48 forks source link

Update tests for issue #1156 #1167

Closed aravindh-krishnamoorthy closed 1 week ago

aravindh-krishnamoorthy commented 2 weeks ago

Tests for issue #1156

Test output

(mathics) ~/git/mathics-core/test/builtin/numbers$ python -m pytest test_linalg.py
=================================================== test session starts ====================================================
platform linux -- Python 3.11.10, pytest-8.3.3, pluggy-1.5.0
rootdir: ~/git/mathics/mathics-core
configfile: pyproject.toml
plugins: anyio-4.6.2.post1, typeguard-4.3.0
collected 32 items

test_linalg.py ................................                                                                      [100%]

===================================================== warnings summary =====================================================
../../../mathics/settings.py:13
  ~/git/mathics/mathics-core/mathics/settings.py:13: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
    import pkg_resources

../../../mathics/core/parser/convert.py:41
test/builtin/numbers/test_linalg.py::test_inverse[None-None-None-None]
  ~/git/mathics/mathics-core/mathics/core/parser/convert.py:41: DeprecationWarning: invalid escape sequence '\!'
    return s.encode("raw_unicode_escape").decode("unicode_escape")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
============================================== 32 passed, 3 warnings in 6.09s ==============================================
rocky commented 1 week ago

@aravindh-krishnamoorthy If you run

$ cd <directory-with-mathics-core>
$ pip install black
$ black mathics builtin/numbers/test_linalg.py

The formatting style test will probably succeed and then we will be able to merge this. Thanks.