check_qualnames_in_tests

glotaran.deprecation.deprecation_utils.check_qualnames_in_tests(qual_names: Sequence[str], importable_indices: Sequence[int])[source]

Test that qualnames import path exists when running tests.

All deprecations should be tested anyway in order to get the proper errors when a deprecation is overdue. This helperfunction also helps to ensure that at least the import paths (qual_names) of the old and new usage exist.

Parameters:
  • qual_names (Sequence[str]) – Sequence of fully qualified module attribute names, optionally with call arguments.

  • importable_indices (Sequence[int]) – Indices of corresponding to qual_names indicating how to slice each qual_name split at ., for the import and attribute checking.