From d89ab632e9b5f9cb892d2e55afa1267eedda8595 Mon Sep 17 00:00:00 2001 From: Sebastien Boeuf Date: Wed, 19 Feb 2020 09:33:27 +0100 Subject: [PATCH] ci: Improve test_memory_mergeable_on stability The integration test test_memory_mergeable_on has been fairly unstable for quite some time now. Because it can take some time for the VM to be spawned and to be able to perform a correct measure of the PSS, this commit simply increases the time before such measure is done. This should return more accurate PSS results, which should help stabilize the test. Fixes #781 Signed-off-by: Sebastien Boeuf (cherry picked from commit ddf6caf95505cfc99a5d10c92a8fc4fc50328862) --- src/main.rs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/main.rs b/src/main.rs index 93d058330..32225a280 100755 --- a/src/main.rs +++ b/src/main.rs @@ -4587,7 +4587,9 @@ mod tests { .spawn() .unwrap(); - thread::sleep(std::time::Duration::new(20, 0)); + // Let enough time for the first VM to be spawned, and to make + // sure the PSS measurement is accurate. + thread::sleep(std::time::Duration::new(60, 0)); // Get initial PSS let old_pss = get_pss(child1.id()); @@ -4617,9 +4619,9 @@ mod tests { .unwrap(); // Let enough time for the second VM to be spawned, and to make - // sure KVM has enough time to merge identical pages between the + // sure KSM has enough time to merge identical pages between the // 2 VMs. - thread::sleep(std::time::Duration::new(30, 0)); + thread::sleep(std::time::Duration::new(60, 0)); // Get new PSS let new_pss = get_pss(child1.id());