psutil.tests.test_misc

Miscellaneous tests.

Module Contents

class TestMisc

Bases:psutil.tests.unittest.TestCase

test_process__repr__(self, func=repr)
test_process__str__(self)
test_no_such_process__repr__(self, func=repr)
test_zombie_process__repr__(self, func=repr)
test_access_denied__repr__(self, func=repr)
test_timeout_expired__repr__(self, func=repr)
test_process__eq__(self)
test_process__hash__(self)
test__all__(self)
test_version(self)
test_process_as_dict_no_new_names(self)
test_memoize(self)
test_memoize_when_activated(self)
test_parse_environ_block(self)
test_supports_ipv6(self)
test_isfile_strict(self)
test_serialization(self)
test_setup_script(self)
test_ad_on_process_creation(self)
test_sanity_version_check(self)
nt
class TestWrapNumbers

Bases:psutil.tests.unittest.TestCase

tearDown
setUp(self)
test_first_call(self)
test_input_hasnt_changed(self)
test_increase_but_no_wrap(self)
test_wrap(self)
test_changing_keys(self)
test_changing_keys_w_wrap(self)
test_real_data(self)
test_cache_first_call(self)
test_cache_call_twice(self)
test_cache_wrap(self)
test_cache_changing_keys(self)
test_cache_clear(self)
test_cache_clear_public_apis(self)
class TestScripts

Bases:psutil.tests.unittest.TestCase

Tests for scripts in the “scripts” directory.

static assert_stdout(exe, *args, **kwargs)
static assert_syntax(exe, args=None)
test_coverage(self)
test_executable(self)
test_disk_usage(self)
test_free(self)
test_meminfo(self)
test_procinfo(self)
test_who(self)
test_ps(self)
test_pstree(self)
test_netstat(self)
test_ifconfig(self)
test_pmap(self)
test_procsmem(self)
test_killall(self)
test_nettop(self)
test_top(self)
test_iotop(self)
test_pidof(self)
test_winservices(self)
test_cpu_distribution(self)
test_temperatures(self)
test_fans(self)
test_battery(self)
test_sensors(self)
class TestRetryDecorator

Bases:psutil.tests.unittest.TestCase

test_retry_success(self, sleep)
test_retry_failure(self, sleep)
test_exception_arg(self, sleep)
test_no_interval_arg(self, sleep)
test_retries_arg(self, sleep)
test_retries_and_timeout_args(self, sleep)
class TestSyncTestUtils

Bases:psutil.tests.unittest.TestCase

tearDown(self)
test_wait_for_pid(self)
test_wait_for_file(self)
test_wait_for_file_empty(self)
test_wait_for_file_no_file(self)
test_wait_for_file_no_delete(self)
test_call_until(self)
class TestFSTestUtils

Bases:psutil.tests.unittest.TestCase

tearDown
setUp(self)
test_open_text(self)
test_open_binary(self)
test_safe_mkdir(self)
test_safe_rmpath(self)
test_chdir(self)
class TestProcessUtils

Bases:psutil.tests.unittest.TestCase

test_reap_children(self)
test_create_proc_children_pair(self)
test_create_zombie_proc(self)
class TestNetUtils

Bases:psutil.tests.unittest.TestCase

bind_socket(self)
test_bind_unix_socket(self)
tcp_tcp_socketpair(self)
test_unix_socketpair(self)
test_create_sockets(self)
class TestOtherUtils

Bases:psutil.tests.unittest.TestCase

test_is_namedtuple(self)