* [BlueZ PATCH v1 1/3] unit: Speed up unit-avdtp test
2026-01-09 9:28 [BlueZ PATCH v1 0/3] Unit tests speed-up Bastien Nocera
@ 2026-01-09 9:29 ` Bastien Nocera
2026-01-09 10:26 ` Unit tests speed-up bluez.test.bot
2026-01-09 9:29 ` [BlueZ PATCH v1 2/3] unit: Speed up unit-gobex-transfer test Bastien Nocera
` (2 subsequent siblings)
3 siblings, 1 reply; 7+ messages in thread
From: Bastien Nocera @ 2026-01-09 9:29 UTC (permalink / raw)
To: linux-bluetooth
Speed up /TP/SIG/SMG/BI-02-C by reducing the timeout length from 1
second to 100 milliseconds.
This reduces the runtime from 1.5 secs to 0.1 secs.
---
unit/test-avdtp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/unit/test-avdtp.c b/unit/test-avdtp.c
index 460982b2c542..9833b03be408 100644
--- a/unit/test-avdtp.c
+++ b/unit/test-avdtp.c
@@ -148,7 +148,7 @@ static gboolean send_pdu(gpointer user_data)
g_assert_cmpint(len, ==, pdu->size);
if (g_str_equal(context->data->test_name, "/TP/SIG/SMG/BI-02-C"))
- g_timeout_add_seconds(1, context_quit, context);
+ g_timeout_add(100, context_quit, context);
if (pdu->fragmented)
return send_pdu(user_data);
--
2.52.0
^ permalink raw reply related [flat|nested] 7+ messages in thread* [BlueZ PATCH v1 2/3] unit: Speed up unit-gobex-transfer test
2026-01-09 9:28 [BlueZ PATCH v1 0/3] Unit tests speed-up Bastien Nocera
2026-01-09 9:29 ` [BlueZ PATCH v1 1/3] unit: Speed up unit-avdtp test Bastien Nocera
@ 2026-01-09 9:29 ` Bastien Nocera
2026-01-09 9:29 ` [BlueZ PATCH v1 3/3] unit: Speed up unit-ringbuf test Bastien Nocera
2026-01-09 22:40 ` [BlueZ PATCH v1 0/3] Unit tests speed-up patchwork-bot+bluetooth
3 siblings, 0 replies; 7+ messages in thread
From: Bastien Nocera @ 2026-01-09 9:29 UTC (permalink / raw)
To: linux-bluetooth
Speed up /gobex/test_packet_put_req_suspend_resume by reducing the
timeout length from seconds to hundreds of milliseconds.
This reduces the runtime from 1.5 secs to 0.1 secs.
---
unit/test-gobex-transfer.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/unit/test-gobex-transfer.c b/unit/test-gobex-transfer.c
index 4fc97f4541b8..d97e0ae430f7 100644
--- a/unit/test-gobex-transfer.c
+++ b/unit/test-gobex-transfer.c
@@ -1123,7 +1123,7 @@ static gssize provide_seq_delay(void *buf, gsize len, gpointer user_data)
if (d->provide_delay > 0) {
g_obex_suspend(d->obex);
- g_timeout_add_seconds(d->provide_delay, resume_obex, d);
+ g_timeout_add(d->provide_delay * 100, resume_obex, d);
d->provide_delay = 0;
}
--
2.52.0
^ permalink raw reply related [flat|nested] 7+ messages in thread* [BlueZ PATCH v1 3/3] unit: Speed up unit-ringbuf test
2026-01-09 9:28 [BlueZ PATCH v1 0/3] Unit tests speed-up Bastien Nocera
2026-01-09 9:29 ` [BlueZ PATCH v1 1/3] unit: Speed up unit-avdtp test Bastien Nocera
2026-01-09 9:29 ` [BlueZ PATCH v1 2/3] unit: Speed up unit-gobex-transfer test Bastien Nocera
@ 2026-01-09 9:29 ` Bastien Nocera
2026-01-09 22:40 ` [BlueZ PATCH v1 0/3] Unit tests speed-up patchwork-bot+bluetooth
3 siblings, 0 replies; 7+ messages in thread
From: Bastien Nocera @ 2026-01-09 9:29 UTC (permalink / raw)
To: linux-bluetooth
Speed up /gobex/test_packet_put_req_suspend_resume by not printing
debug for each of the million of iterations of our test.
If we carry on printing this, then either the terminal's output speed,
or the debug capture from the test suite will throttle the test.
This reduces the runtime from 3.3 secs to 0.007 secs.
---
unit/test-ringbuf.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/unit/test-ringbuf.c b/unit/test-ringbuf.c
index b1cf51115a41..0e348a49b8c9 100644
--- a/unit/test-ringbuf.c
+++ b/unit/test-ringbuf.c
@@ -57,9 +57,6 @@ static void test_power2(const void *data)
while (size3 < i && size3 < SIZE_MAX)
size3 <<= 1;
- tester_debug("%zu -> size1=%zu size2=%zu size3=%zu\n",
- i, size1, size2, size3);
-
g_assert(size1 == size2);
g_assert(size2 == size3);
g_assert(size3 == size1);
--
2.52.0
^ permalink raw reply related [flat|nested] 7+ messages in thread* Re: [BlueZ PATCH v1 0/3] Unit tests speed-up
2026-01-09 9:28 [BlueZ PATCH v1 0/3] Unit tests speed-up Bastien Nocera
` (2 preceding siblings ...)
2026-01-09 9:29 ` [BlueZ PATCH v1 3/3] unit: Speed up unit-ringbuf test Bastien Nocera
@ 2026-01-09 22:40 ` patchwork-bot+bluetooth
3 siblings, 0 replies; 7+ messages in thread
From: patchwork-bot+bluetooth @ 2026-01-09 22:40 UTC (permalink / raw)
To: Bastien Nocera; +Cc: linux-bluetooth
Hello:
This series was applied to bluetooth/bluez.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:
On Fri, 9 Jan 2026 10:28:59 +0100 you wrote:
> With those small changes, as well as running tests concurrently using
> meson, I was able to make the whole test suite run in less than 4
> seconds on my desktop system, with a baseline of 50 seconds for "make
> -j8 check" under the autotools.
>
> make -j8 check: 50 seconds
> meson before changes: 13 seconds
> meson after changes: 3.6 seconds
>
> [...]
Here is the summary with links:
- [BlueZ,v1,1/3] unit: Speed up unit-avdtp test
https://git.kernel.org/pub/scm/bluetooth/bluez.git/?id=51d93aca7afa
- [BlueZ,v1,2/3] unit: Speed up unit-gobex-transfer test
https://git.kernel.org/pub/scm/bluetooth/bluez.git/?id=027e29c34225
- [BlueZ,v1,3/3] unit: Speed up unit-ringbuf test
https://git.kernel.org/pub/scm/bluetooth/bluez.git/?id=00e5c016145a
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 7+ messages in thread