| Total Complexity | 3 |
| Total Lines | 27 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | import pytest |
||
| 2 | |||
| 3 | from pocketutils.tools.sys_tools import SystemTools |
||
| 4 | |||
| 5 | |||
| 6 | class TestSysTools: |
||
| 7 | def test_add_signals(self): |
||
| 8 | pass |
||
| 9 | |||
| 10 | def test_get_env_info(self): |
||
| 11 | data = SystemTools.get_env_info(include_insecure=True) |
||
| 12 | assert len(data) > 20 |
||
| 13 | assert "pid" in data |
||
| 14 | assert "disk_used" in data |
||
| 15 | assert "hostname" in data |
||
| 16 | assert "locale" in data |
||
| 17 | |||
| 18 | def test_list_imports(self): |
||
| 19 | data = SystemTools.list_package_versions() |
||
| 20 | assert len(data) > 5 |
||
| 21 | assert "orjson" in data |
||
| 22 | assert data["orjson"].startswith("3.") # change when updated |
||
| 23 | |||
| 24 | |||
| 25 | if __name__ == "__main__": |
||
| 26 | pytest.main() |
||
| 27 |