Download tests/test_eval.py from debudash/slm-training: direct link, hf CLI and curl.
- Browser
- Download file 610 Bytes
-
https://huggingface.co/debudash/slm-training/resolve/main/tests/test_eval.py
- Command line
-
hf download hf://debudash/slm-training/tests/test_eval.py
-
curl -L -o test_eval.py https://huggingface.co/debudash/slm-training/resolve/main/tests/test_eval.py
610 Bytes
| """eval.py helpers.""" | |
| from eval import drop_empty_modal_tokens | |
| def test_empty_modal_tokens_are_removed_so_the_modal_setup_login_applies(): | |
| # ISSUE-001, found by: all eight v3 evals failing with Modal AuthError "Token missing". | |
| env = {"MODAL_TOKEN_ID": "", "MODAL_TOKEN_SECRET": "", "OTHER": ""} | |
| drop_empty_modal_tokens(env) | |
| assert env == {"OTHER": ""} | |
| def test_real_modal_tokens_are_kept(): | |
| env = {"MODAL_TOKEN_ID": "ak-123", "MODAL_TOKEN_SECRET": "as-456"} | |
| drop_empty_modal_tokens(env) | |
| assert env == {"MODAL_TOKEN_ID": "ak-123", "MODAL_TOKEN_SECRET": "as-456"} | |