diff options
author | Benjamin Berg <bberg@redhat.com> | 2018-04-30 12:27:24 +0200 |
---|---|---|
committer | Benjamin Berg <bberg@redhat.com> | 2018-04-30 12:28:43 +0200 |
commit | a42477144c6972e05248bee37a2e44631248afd7 (patch) | |
tree | b1a68387c92ef87bb73ffa346043e16ac091f826 | |
parent | f7829181cea22a4ee8045ec63b7c68736af9c91d (diff) | |
download | gnome-settings-daemon-benzea/test_dim_race_fix.tar.gz |
power: Resolve race condition in test_dim testbenzea/test_dim_race_fix
Without this change we wait exactly as long as gsd-power does before
dimming. Resolve this race condition by waiting a second longer.
-rwxr-xr-x | plugins/power/test.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/power/test.py b/plugins/power/test.py index 3157c6b0..e52bbbf4 100755 --- a/plugins/power/test.py +++ b/plugins/power/test.py @@ -708,7 +708,7 @@ class PowerPluginTest(gsdtestcase.GSDTestCase): self.assertEqual(self.get_status(), gsdpowerenums.GSM_PRESENCE_STATUS_AVAILABLE) # Wait and check we're not idle, but dimmed - self.check_dim(gsdpowerconstants.MINIMUM_IDLE_DIM_DELAY) + self.check_dim(gsdpowerconstants.MINIMUM_IDLE_DIM_DELAY + 1) # Give time for the brightness to change time.sleep(2) level = self.get_brightness(); |