def test__get_path_based_modules(status_wrapper):
    """Use the list of inbuilt modules as reference to check against."""
    included_modules_path = Path(py3status.__file__).resolve().parent / "modules"
    status_wrapper.options.__dict__["include_paths"] = [included_modules_path]
    assert included_modules_path.exists()
    expected_keys = [
        n.stem for n in included_modules_path.iterdir() if n.suffix == ".py"
    ]
    modules = status_wrapper._get_path_based_modules()
    assert sorted(modules) == sorted(expected_keys)
Use the list of inbuilt modules as reference to check against.
tests/test_user_modules.py