text: Title: Apparent leaks between tests with (customised) qapp
  Body: The [pytest-qt documentation](https://pytest-qt.readthedocs.io/en/latest/qapplication.html#testing-custom-qapplications) explains how to create a `QApplication` subclass from your own project which will then take the place of the default fixture `qapp` used to make a default `QApplication`. It tells you to put that in the conftest.py file in the relevant testing directory, and to give it "session" scope. From my experience any other scope causes horrendous crashes.
  
  But what this means is that this fixture is only run once in your whole test session. `qapp` appears to be a strange beast, because you can add attributes to it, get your application code to change these attributes, etc. So... it's kind of half an object and half a function (which is only called once).
  
  Dealing with the above wouldn't be that hard: you can prefer methods to attributes (e.g. `MyApp.set_version(...)` rather than `MyApp.version = ...`).
  
  But there's a bigger problem I've just experienced: apparent leaking of patches between tests. This test, which checks that `setWindowTitle` is set on `app.main_window`, passes OK when run on its own:
  
  ```
      def test_window_title_updated_on_new_doc(request, qapp):
          t_logger.info(f'\n>>>>>> test name: {request.node.originalname}')
          qapp.main_window =  main_window.AutoTransMainWindow()
          with unittest.mock.patch.object(qapp.main_window, 'setWindowTitle') as mock_set_wt:
              qapp.try_to_create_new_doc()
          mock_set_wt.assert_called_once()
  
  ```
  ... but there is another method before this:
  
  ```
      @pytest.mark.parametrize('close_result', [True, False])
      def test_try_to_create_new_doc_returns_expected_result(request, close_result, qapp):
          t_logger.info(f'\n>>>>>> test name: {request.node.originalname}, close_result {close_result}')
          with unittest.mock.patch.object(qapp, 'main_window'):
              qapp.open_document = project.Project()
              with unittest.mock.patch.object(qapp, 'try_to_close_curr_doc') as mock_try:
                  mock_try.return_value = close_result
                  create_result = qapp.try_to_create_new_doc()
          assert close_result == create_result
  
  ```
  ... this tests that `app.try_to_create_new_doc` returns the same boolean value as  `try_to_close_curr_doc`. This method passes with `close_result` as both `True` and `False`.
  
  When both tests are run in the same `pytest` command, however, I get the following error on the *second* test (i.e. `test_window_updated_on_new_doc`):
  
  ```
      E           AssertionError: Expected 'setWindowTitle' to have been called once. Called 2 times.
      E           Calls: [call('Auto_trans 0.0.1 - No projects open'),
      E            call('Auto_trans 0.0.1 - Project: Not yet saved')].
  
  ```
  These calls happened during the *first* test, i.e. `test_try_to_create_new_doc_returns_expected_result`, something which I've been able to verify, but they get reported as fails during the *second* test!
  
  Does anyone know what to do about this?
  
  
  
  