tests: turn check if manager cannot be intialized into macro

We need to check the same thing in multiple tests. Use a shared
macro to make it easier to update the list of errnos.

Change the errno code for "unitialized cgroup fs" for ENOMEDIUM.
Exec format error looks like something more serious.

This fixes test-execute invocation in mock.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2015-12-02 09:50:00 -05:00
parent ade61d3b48
commit 8b3aa503c1
8 changed files with 23 additions and 7 deletions
+1 -1
View File
@@ -2135,7 +2135,7 @@ int cg_unified(void) {
else if (F_TYPE_EQUAL(fs.f_type, TMPFS_MAGIC))
unified_cache = false;
else
return -ENOEXEC;
return -ENOMEDIUM;
return unified_cache;
}