Commit graph

12 commits

Author SHA1 Message Date
Benjamin Berg
4f3aec794e tests: Add delete_cb for network panel testing
Having a delete_cb to handle connection removal is useful for other
tests. Add the function in preparation for VPN testing.
2018-05-29 15:19:50 +02:00
Benjamin Berg
edc85abf91 tests: Return NMRemoteConnection from add_cb
The add_cb can be useful in other tests. Return the remote connection in
the info struct to allow its use in other situations.
2018-05-29 15:19:30 +02:00
Benjamin Berg
bfdd2e0a8f tests: Use the same NMClient as the panel
Doing so means we handle the same events as the panel. This probably
makes no difference, but this way it is guaranteed we are not getting
weird inconsistencies during testing.

Also fixes a NMClient memory leak in the process.
2018-05-29 15:19:22 +02:00
Benjamin Berg
b14e5145f0 tests: Improve helpers to wait for NM events
This adds support for waiting on an NMConnection object and also allows
waiting for both signals and properties.
2018-05-29 15:19:15 +02:00
Benjamin Berg
77edec52ed tests: Allow creating VPNs in the NM test service
This is in preparation for adding VPN related tests.
2018-05-29 15:19:00 +02:00
Benjamin Berg
7c43f95ef9 tests: Add trivial test to check empty network panel
If there are no connections or devices then we should not be showing
e.g. the Bluetooth list. Add a simple check that this is handled
correctly.
2018-05-29 15:17:50 +02:00
Benjamin Berg
f3322b495c tests: Do not show_all the network panel
This has the side effect of showing UI elements that should not be
visible at startup. Just add the correct gtk_widget_show calls to show
all relevant widgets.
2018-05-29 15:17:24 +02:00
Georges Basile Stavracas Neto
af0186aaf9 project: Update meson files
I probably have OCD. Seeing these files
with this poor alignment gives me physical
pain.
2018-05-03 00:45:29 -03:00
Benjamin Berg
f655e46ce7 tests/network: Add basic testing of network panel
This adds tests for the network panel based on the test service found in
NetworkManager. Another possible solution may be to use the one from
dbusmock, however NetworkManager already has readily available code to
write tests in C which makes checking the widget hierarchy easier.
2018-05-02 22:29:33 +00:00
Benjamin Berg
466d91afd3 tests/network: Fix deprecation warning in NM test service
This just fixes a simple deprecation warning in the NetworkManager test
service.
2018-05-02 22:29:32 +00:00
Benjamin Berg
9bab137bb4 tests/network: Add status and carrier setting to NM test service
This adds a bit of new functionality to the test service to set the
status and reason for the status change as well as whether the carrier
is connected.
2018-05-02 22:29:32 +00:00
Benjamin Berg
2ebdb532cf tests/network: Copy files from network manager for network panel testing
This copies a number of files from network manager in preparation of
adding network panel tests.
2018-05-02 22:29:32 +00:00