Skip to content

Commit 0ea8f7e

Browse files
renaming functions
1 parent f417060 commit 0ea8f7e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/test_shadowed_module.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
from sentry_sdk.integrations import _DEFAULT_INTEGRATIONS, Integration
1111

1212

13-
def unrecognized_dependencies(tree):
13+
def find_unrecognized_dependencies(tree):
1414
"""
1515
Finds unrecognized imports in the AST for a Python module. In an empty
1616
environment the set of non-standard library modules is returned.
@@ -45,7 +45,7 @@ def unrecognized_dependencies(tree):
4545
return unrecognized_dependencies
4646

4747

48-
def test_shadowed_module(sentry_init):
48+
def test_shadowed_modules_when_importing_integrations(sentry_init):
4949
"""
5050
Check that importing integrations for third-party module raises an
5151
DidNotEnable exception when the associated module is shadowed by an empty
@@ -77,7 +77,7 @@ def test_shadowed_module(sentry_init):
7777
spec = importlib.util.find_spec(module_path)
7878
source = pathlib.Path(spec.origin).read_text(encoding="utf-8")
7979
tree = ast.parse(source, filename=spec.origin)
80-
integration_dependencies = unrecognized_dependencies(tree)
80+
integration_dependencies = find_unrecognized_dependencies(tree)
8181
for dependency in integration_dependencies:
8282
sys.modules[dependency] = types.ModuleType(dependency)
8383
with pytest.raises(integrations.DidNotEnable):

0 commit comments

Comments
 (0)