Cgroup module unit tests and bug fixes.