If cgroup swap memory limit isn't enabled, then
the -m flag doesn't work and the container that is created for
both of these tests is very large. Because we are trying to run the
containers out of memory, this takes a very long time and causes the
tests to fail most of the time.
Follow-up to #17913
Signed-off-by: Christopher Jones <tophj@linux.vnet.ibm.com>
| ... | ... |
@@ -46,7 +46,7 @@ func (s *DockerSuite) TestEventsRedirectStdout(c *check.C) {
|
| 46 | 46 |
} |
| 47 | 47 |
|
| 48 | 48 |
func (s *DockerSuite) TestEventsOOMDisableFalse(c *check.C) {
|
| 49 |
- testRequires(c, DaemonIsLinux, oomControl, memoryLimitSupport, NotGCCGO) |
|
| 49 |
+ testRequires(c, DaemonIsLinux, oomControl, memoryLimitSupport, NotGCCGO, swapMemorySupport) |
|
| 50 | 50 |
|
| 51 | 51 |
errChan := make(chan error) |
| 52 | 52 |
go func() {
|
| ... | ... |
@@ -76,7 +76,7 @@ func (s *DockerSuite) TestEventsOOMDisableFalse(c *check.C) {
|
| 76 | 76 |
} |
| 77 | 77 |
|
| 78 | 78 |
func (s *DockerSuite) TestEventsOOMDisableTrue(c *check.C) {
|
| 79 |
- testRequires(c, DaemonIsLinux, oomControl, memoryLimitSupport, NotGCCGO, NotArm) |
|
| 79 |
+ testRequires(c, DaemonIsLinux, oomControl, memoryLimitSupport, NotGCCGO, NotArm, swapMemorySupport) |
|
| 80 | 80 |
|
| 81 | 81 |
errChan := make(chan error) |
| 82 | 82 |
observer, err := newEventObserver(c) |