process-cpp  3.0.0
A simple convenience library for handling processes in C++11.
linux_process_test.cpp File Reference
+ Include dependency graph for linux_process_test.cpp:

Go to the source code of this file.

Functions

 TEST (LinuxProcess, accessing_proc_stats_works)
 
 TEST (LinuxProcess, accessing_proc_oom_score_works)
 
 TEST (LinuxProcess, accessing_proc_oom_score_adj_works)
 
 TEST (LinuxProcess, adjusting_proc_oom_score_adj_works)
 
 TEST (LinuxProcess, adjusting_proc_oom_score_adj_to_privileged_values_only_works_if_root)
 
 TEST (LinuxProcess, trying_to_write_an_invalid_oom_score_adj_throws)
 
 TEST (LinuxProcess, adjusting_proc_oom_adj_works)
 
 TEST (LinuxProcess, adjusting_proc_oom_adj_to_privileged_values_does_not_work)
 
 TEST (LinuxProcess, trying_to_write_an_invalid_oom_adj_throws)
 

Function Documentation

TEST ( LinuxProcess  ,
accessing_proc_stats_works   
)

Definition at line 31 of file linux_process_test.cpp.

References core::posix::empty, core::posix::fork(), core::posix::linux::proc::process::running, and core::posix::exit::success.

+ Here is the call graph for this function:

TEST ( LinuxProcess  ,
accessing_proc_oom_score_works   
)

Definition at line 42 of file linux_process_test.cpp.

References core::posix::this_process::instance().

+ Here is the call graph for this function:

TEST ( LinuxProcess  ,
accessing_proc_oom_score_adj_works   
)

Definition at line 48 of file linux_process_test.cpp.

References core::posix::this_process::instance().

+ Here is the call graph for this function:

TEST ( LinuxProcess  ,
adjusting_proc_oom_score_adj_works   
)
TEST ( LinuxProcess  ,
adjusting_proc_oom_score_adj_to_privileged_values_only_works_if_root   
)

Definition at line 88 of file linux_process_test.cpp.

References core::posix::this_process::instance(), and core::posix::linux::proc::process::OomScoreAdj::min_value().

+ Here is the call graph for this function:

TEST ( LinuxProcess  ,
trying_to_write_an_invalid_oom_score_adj_throws   
)

Definition at line 104 of file linux_process_test.cpp.

References EXPECT_ANY_THROW(), core::posix::this_process::instance(), and core::posix::linux::proc::process::OomScoreAdj::min_value().

+ Here is the call graph for this function:

TEST ( LinuxProcess  ,
adjusting_proc_oom_adj_works   
)
TEST ( LinuxProcess  ,
adjusting_proc_oom_adj_to_privileged_values_does_not_work   
)

Definition at line 134 of file linux_process_test.cpp.

References core::posix::this_process::instance(), and core::posix::linux::proc::process::OomAdj::min_value().

+ Here is the call graph for this function:

TEST ( LinuxProcess  ,
trying_to_write_an_invalid_oom_adj_throws   
)

Definition at line 150 of file linux_process_test.cpp.

References EXPECT_ANY_THROW(), core::posix::this_process::instance(), and core::posix::linux::proc::process::OomAdj::min_value().

+ Here is the call graph for this function: