Browse code

Skip apparmor tests on User Namespace

Signed-off-by: Alexander Morozov <lk4d4@docker.com>

Alexander Morozov authored on 2015/11/18 04:49:31
Showing 1 changed files
... ...
@@ -2854,7 +2854,7 @@ func (s *DockerSuite) TestMountIntoSys(c *check.C) {
2854 2854
 
2855 2855
 func (s *DockerSuite) TestRunUnshareProc(c *check.C) {
2856 2856
 	// Not applicable on Windows as uses Unix specific functionality
2857
-	testRequires(c, Apparmor, DaemonIsLinux)
2857
+	testRequires(c, Apparmor, DaemonIsLinux, NotUserNamespace)
2858 2858
 
2859 2859
 	name := "acidburn"
2860 2860
 	if out, _, err := dockerCmdWithError("run", "--name", name, "jess/unshare", "unshare", "-p", "-m", "-f", "-r", "--mount-proc=/proc", "mount"); err == nil || !strings.Contains(out, "Permission denied") {
... ...
@@ -3233,7 +3233,7 @@ func (s *DockerSuite) TestAppArmorTraceSelf(c *check.C) {
3233 3233
 
3234 3234
 func (s *DockerSuite) TestAppArmorDeniesChmodProc(c *check.C) {
3235 3235
 	// Not applicable on Windows as uses Unix specific functionality
3236
-	testRequires(c, SameHostDaemon, Apparmor, DaemonIsLinux)
3236
+	testRequires(c, SameHostDaemon, Apparmor, DaemonIsLinux, NotUserNamespace)
3237 3237
 	_, exitCode, _ := dockerCmdWithError("run", "busybox", "chmod", "744", "/proc/cpuinfo")
3238 3238
 	if exitCode == 0 {
3239 3239
 		// If our test failed, attempt to repair the host system...