Commit Graph

7 Commits

Author SHA1 Message Date
Aleksander Morgado
53784f95aa tests,fixture: fix warnings with -Wsign-compare
tests/test-fixture.c:130:28: error: comparison of integer expressions of different signedness: ‘gboolean’ {aka ‘int’} and ‘guint’ {aka ‘unsigned int’} [-Werror=sign-compare]
    130 |         if (modem_expected == n_modems) {
        |                            ^~
2020-01-31 14:52:49 +01:00
Ben Chan
254f2e3412 plugins: remove explicit GDestroyNotify cast on g_free / g_object_unref
g_free and g_object_unref are in form of  `void (*)(gpointer)`, which
matches the GDestroyNotify signature. An explicit GDestroyNotify cast on
g_free and g_object_unref is thus not needed.
2017-03-29 10:22:18 +02:00
Aleksander Morgado
dfd111f291 tests,test-fixture: don't rely on other threads to update dbus properties
We were wrongly using a main loop in the port context thread to manage the
global main context. That was silently making the DBus property notifications
kind of work, as they were being updated via another thread, so here we could
just sleep() and recheck the property values.

Given that having that unrelated thread updating the dbus properties of our
MMManager object is not a good thing, we'll instead totally ignore that and
fully re-create the MMManager in each iteration with the sync() method, which
has its own internal thread.
2016-01-16 17:59:49 +01:00
Aleksander Morgado
a72b120798 tests,fixture: fix comment 2014-10-17 15:55:12 +02:00
Ben Chan
1e5ec7e1b1 tests: increase timeout for starting ModemManager on test bus
The timeout for starting ModemManager on the test bus was 3s, which is
sufficient under normal conditions. However, when running ModemManager
tests on a build infrastructure under a heavy load, we've observed that
the timeout isn't always sufficient and that becomes the source of false
test failures. This patch increases the timeout to 30s, which shouldn't
introduce any unexpected behavior under normnal conditions while
addressing the timeout issue on heavily loaded systems.
2014-10-05 15:37:47 -05:00
Ben Chan
3d378bef5d tests: consistently use spaces for indentation 2014-05-21 11:58:03 +02:00
Aleksander Morgado
bff2a8d2f2 tests: added support for DBus service tests
We can now run 'simulated' modems against a ModemManager running in its own
session bus.
2014-02-13 13:41:58 +01:00