##### SUMMARY

(converted from project card created by @webknjaz)

When conftest in unit test contains something like `from ansible_collections.yum_unit_test_migration_spec.yum_collection.tests.unit.compat.mock import patch`, it will result in `E   ModuleNotFoundError: No module named 'ansible_collections'`.

The workaround is to add a boilerplate `conftest.py` into tests root: https://github.com/webknjaz/fqcn_conftest_repro/commit/b07826c54e01c6965cb63aa0a8cada602a311911

##### COMPONENT NAME

ansible-test

##### ANSIBLE VERSION

devel

##### CONFIGURATION

N/A

##### OS / ENVIRONMENT

N/A

##### STEPS TO REPRODUCE

Repro: https://github.com/webknjaz/fqcn_conftest_repro/tree/77347551f5fdd5185b26c752074878ea37055b77

Failure demo: https://github.com/webknjaz/fqcn_conftest_repro/runs/216648897#step:5:41

Hack demo: https://github.com/webknjaz/fqcn_conftest_repro/runs/216654164#step:5:65

##### EXPECTED RESULTS

Tests pass.

##### ACTUAL RESULTS

Tests fail.

"""
    :type args: UnitsConfig
    """
    handle_layout_messages(data_context().content.unit_messages)
    changes = get_changes_filter(args)
    require = args.require + changes
    include = walk_internal_targets(walk_units_targets(), args.include, args.exclude, require)
    paths = [target.path for target in include]
    remote_paths = [path for path in paths
                    if is_subdir(path, data_context().content.unit_module_path)
                    or is_subdir(path, data_context().content.unit_module_utils_path)]
    if not paths:
        raise AllTargetsSkipped()
    if args.python and args.python in REMOTE_ONLY_PYTHON_VERSIONS and not remote_paths:
        raise AllTargetsSkipped()
    if args.delegate:
        raise Delegate(require=changes, exclude=args.exclude)
    version_commands = []
    available_versions = sorted(get_available_python_versions(list(SUPPORTED_PYTHON_VERSIONS)).keys())