Pradyot Ranjan

Results 149 comments of Pradyot Ranjan

One easy fix is to rename functions like `test_function` to maybe `function1` and others respectively. Due to pytest naming convention, it recognises these as test functions. Edit: I just noticed...

yes we can also do that.

Why are the CI tasks failing?

These are mostly the failures we have to deal with : ``` FAILED tests/unit/test_expression_tree/test_operations/test_latexify.py::TestLatexify::test_latexify - File "/Users/runner/work/PyBaMM/PyBaMM/pybamm/expression_tree/operations/latexify.py", line 82 geo_latex = f"\quad {rng_min} < {name} < {rng_max}" ^ SyntaxError: invalid...

I did encounter `anytree` but not the `test_plot` error. So that might be the case. Also we can remove `invalid escape sequence` failure by using raw string, instead of: https://github.com/pybamm-team/PyBaMM/blob/39cff38cc7c424285761101c3e046e0d04af5dff/pybamm/expression_tree/operations/latexify.py#L82...

We should have more number of checks with this.

How to get covergae report? I tried running Running ``` python -m pytest --cov tests/unit ``` but it's unable to find tests. Also running ``` coverage run -m unittest discover...

> The command should be: > > ``` > pytest --cov=pybamm tests/unit > ``` > > More on coverage with pytest here - https://learn.scientific-python.org/development/guides/coverage/ Oh wrong command. This was embarrassing....

Is the doctests failure related to changes in this PR? Do I need to integrate `xdoctest` for it to pass?

> > Is the doctests failure related to changes in this PR? Do I need to integrate `xdoctest` for it to pass? > > The tests appear to be passing...