Spaces:
Runtime error
Runtime error
Download tests/test_numeric_validator_wolfram_extraction.py from shazhass/bacpilot-backend: direct link, hf CLI and curl.
- Browser
- Download file 600 Bytes
-
https://huggingface.co/spaces/shazhass/bacpilot-backend/resolve/main/tests/test_numeric_validator_wolfram_extraction.py
- Command line
-
hf download hf://spaces/shazhass/bacpilot-backend/tests/test_numeric_validator_wolfram_extraction.py
-
curl -L -o test_numeric_validator_wolfram_extraction.py https://huggingface.co/spaces/shazhass/bacpilot-backend/resolve/main/tests/test_numeric_validator_wolfram_extraction.py
600 Bytes
| from types import SimpleNamespace | |
| from app.services.numeric_validator import _extract_first_useful_wolfram_text | |
| def test_extracts_rhs_from_wolfram_derivative_plaintext() -> None: | |
| pods = [ | |
| SimpleNamespace( | |
| title="Derivative", | |
| plaintext="d/dx(x^2) = 2 x", | |
| ) | |
| ] | |
| assert _extract_first_useful_wolfram_text(pods) == "2 x" | |
| def test_extracts_plaintext_without_equals() -> None: | |
| pods = [ | |
| SimpleNamespace( | |
| title="Result", | |
| plaintext="2 x", | |
| ) | |
| ] | |
| assert _extract_first_useful_wolfram_text(pods) == "2 x" | |