Spaces:
Sleeping
Sleeping
Download dataset/problem_12/test.py from Viraj0112/rl_code_fix_env: direct link, hf CLI and curl.
- Browser
- Download file 369 Bytes
-
https://huggingface.co/spaces/Viraj0112/rl_code_fix_env/resolve/main/dataset/problem_12/test.py
- Command line
-
hf download hf://spaces/Viraj0112/rl_code_fix_env/dataset/problem_12/test.py
-
curl -L -o test.py https://huggingface.co/spaces/Viraj0112/rl_code_fix_env/resolve/main/dataset/problem_12/test.py
369 Bytes
| import unittest | |
| from dataset.problem_12.buggy import parse_pairs | |
| class TestParsePairs(unittest.TestCase): | |
| def test_simple(self): | |
| self.assertEqual(parse_pairs("a=1,b=2"), {"a": 1, "b": 2}) | |
| def test_spaces(self): | |
| self.assertEqual(parse_pairs("x = 10, y = 20"), {"x": 10, "y": 20}) | |
| if __name__ == "__main__": | |
| unittest.main() | |