1. 07 Dec, 2020 2 commits
  2. 04 Dec, 2020 1 commit
  3. 01 Dec, 2020 5 commits
  4. 25 Nov, 2020 3 commits
  5. 10 Nov, 2020 5 commits
  6. 06 Nov, 2020 1 commit
  7. 04 Nov, 2020 1 commit
  8. 02 Oct, 2020 1 commit
    • Benjamin Berg's avatar
      tests: Fix test not failing on error · 6dc699ae
      Benjamin Berg authored
      An assertion that is raised within a callback will not be swallowed by
      the C code that called the function. To ensure that errors will be
      noticable, pass the result back to the surrounding scope and check it
  9. 01 Oct, 2020 1 commit
  10. 01 Apr, 2020 2 commits
  11. 27 Mar, 2020 5 commits
    • Marco Trevisan's avatar
      tests/fprintd: Add checks for delete enrolled fingers permissions · 90298134
      Marco Trevisan authored
      The test doesn't need any assertion because we're calling DeleteEnrolledFingers
      and in case it fails a net.reactivated.Fprint.Error.PermissionDenied error
      would be thrown, and thus an exception would be raised at python level, making
      the test to fail.
    • Bastien Nocera's avatar
    • Bastien Nocera's avatar
      tests/fprintd: Fix claim_from_other_client_is_released_when_vanished on CI · 6a1fffae
      Bastien Nocera authored
      test_claim_from_other_client_is_released_when_vanished would fail on
      the CI but work on a local system because we wouldn't want long enough
      for the "vanished" code path to be taken into account. Add a small
      timeout to make sure it works on the CI as well.
    • Bastien Nocera's avatar
      tests/fprintd: Fix test_enroll_invalid_storage_dir test · 47bd3f7f
      Bastien Nocera authored
      enroll_image() was always waiting for enroll-completed rather than for
      what the caller expected as the result.
      FAIL: test_enroll_invalid_storage_dir (__main__.FPrintdVirtualDeviceClaimedTest)
      Traceback (most recent call last):
        File "/home/hadess/Projects/jhbuild/fprintd/tests/fprintd.py", line 661, in test_enroll_invalid_storage_dir
          self.enroll_image('whorl', expected_result='enroll-failed')
        File "/home/hadess/Projects/jhbuild/fprintd/tests/fprintd.py", line 384, in enroll_image
        File "/home/hadess/Projects/jhbuild/fprintd/tests/fprintd.py", line 373, in wait_for_result
          self.assertEqual(self._last_result, expected)
      AssertionError: 'enroll-failed' != 'enroll-completed'
      - enroll-failed
      + enroll-completed
    • Marco Trevisan's avatar
      tests/fprintd: Add missing implementation of list_tests · eccd790d
      Marco Trevisan authored
      Use unittest_inspector that we provide for meson tests inspection as well
  12. 23 Mar, 2020 1 commit
    • Timothy Gu's avatar
      tests/fprintd: Allow tests to run even when virtual device is not available · 4a3ae5cc
      Timothy Gu authored
      The test file calls self.daemon_start() in order to start fprintd and
      locate the virtual image device that's needed for the test to run.
      However, since the virtual image driver is not available on all
      libfprint installations, the test should be skipped if the driver is not
      The skipping mechanism used to work, by checking if self.device is None.
      This is based on the assumption that self.device would be set to None in
      cases where the driver is not available. However, even in the past
      self.device is only set to None in the tearDown method and not in setUp,
      so presumably in edge cases it didn't entirely work.
      However, since 0fb4f3b0 which
      consistently removes the self.device attribute rather than setting it to
      None, the "self.device is None" check no longer works. In particular,
      the following error message is shown:
          test_manager_get_default_device (__main__.FPrintdManagerTests) ...
          Did not find virtual device! Probably libfprint was build without
          the corresponding driver!
      After this patch, the following is shown:
          test_manager_get_default_device (__main__.FPrintdManagerTests) ...
          Did not find virtual device! Probably libfprint was build without
          the corresponding driver!
          skipped 'Need virtual_image device to run the test'
      We fix this bug by consistently setting self.device to None, in both the
      setUp method before daemon_start gets called, and in tearDown. We also
      make the same change to self.manager for consistency.
      The issue was not caught on CI, as the CI configuration always installs
      a libfprint version that has the virtual_image device explicitly enabled
      in the preparation phase.
  13. 17 Mar, 2020 12 commits