Refactor test-nodes

Move testnodes to test_nodes.hpp. Add command work-load for CPU
and RAM statistics and simplify statistics.