mirror of
https://gitlab.freedesktop.org/libfprint/fprintd.git
synced 2026-05-05 00:37:58 +02:00
tests/fprintd: Check that we can't try to release a device while closing
This commit is contained in:
parent
b92f39be3d
commit
02bd36d8d9
1 changed files with 11 additions and 0 deletions
|
|
@ -2297,6 +2297,17 @@ class FPrintdVirtualDeviceStorageClaimedTest(FPrintdVirtualStorageDeviceBaseTest
|
|||
with self.assertFprintError('Internal'):
|
||||
self.device.Release()
|
||||
|
||||
def test_release_fails_while_closing(self):
|
||||
self.send_sleep(300)
|
||||
self.call_device_method_async('Release', '()', [])
|
||||
self.wait_for_result(max_wait=10)
|
||||
self.assertFalse(self.get_all_async_replies())
|
||||
|
||||
with self.assertFprintError('AlreadyInUse'):
|
||||
self.device.Release()
|
||||
|
||||
self.wait_for_device_reply()
|
||||
self.assertIn(GLib.Variant('()', ()), self.get_all_async_replies())
|
||||
|
||||
class FPrintdVirtualDeviceVerificationTests(FPrintdVirtualDeviceBaseTest):
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue