()
| 397 | |
| 398 | |
| 399 | def test_scan_process_bss_for_python_version(): |
| 400 | # GIVEM |
| 401 | |
| 402 | memory = ( |
| 403 | b"garbagegarbagePython 3.8.3 (default, May 22 2020, 23:30:25)garbagegarbage" |
| 404 | ) |
| 405 | bss = Mock() |
| 406 | # WHEN |
| 407 | |
| 408 | with patch("pystack._pystack.copy_memory_from_address", return_value=memory): |
| 409 | major, minor = scan_process_bss_for_python_version(0, bss) |
| 410 | |
| 411 | # THEN |
| 412 | |
| 413 | assert major == 3 |
| 414 | assert minor == 8 |
| 415 | |
| 416 | |
| 417 | def test_scan_process_bss_for_python_version_failure(): |
nothing calls this directly
no test coverage detected