tests: Reduce sleep time when waiting for various daemons to die
authorKienan Stewart <kstewart@efficios.com>
Thu, 31 Aug 2023 18:00:26 +0000 (14:00 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 21 Dec 2023 21:38:35 +0000 (16:38 -0500)
commitfec7cc14f54b887abb2b43687783470710dc295a
treea1eb219ae002a97e7146286ec056313b67461856
parentfd6ecee841f0fd100c01975f1facb2c5406f9df5
tests: Reduce sleep time when waiting for various daemons to die

Motivation
==========

Using the rough duration of the tests 'Wait after kill \w+ daemon',
approximately 200s were being spent in those areas when running
non-root, non-destructive tests on my development machine.

```
$ find . -iname '*.log' -exec grep -A4 -HE 'Wait for kill [a-z]+ daemon'
{} \; | grep duration_ms | cut -d':' -f2 | datamash sum 1
198078.707216
```

Solution
========

The `stop_x_opt()` functions with timers in `tests/utils/utils.sh`
have the timeouts multiplied by 5 to reduce the counted sleep interval
to 0.1s.

After applying this change, the time spent in the tests as counted
with the find command in the 'Motivation' section above was reduced to
92061.768ms, a reduction of about 1.5 minutes.

Known drawbacks
===============

None

Change-Id: I1d4ad899808f37f6cb7b88bbab0ff05ab0c2b787
Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
tests/utils/utils.sh
This page took 0.024306 seconds and 4 git commands to generate.