We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
# File: pages/home_page.py class HomePage: """ Module description """ def __init__(self) -> None: pass def params_navigation(self): """ Method description """ print("params_navigation") # File: tests/test_file_tests.py class TestClassTest: def test_without_method_definition( self, fixture_from_main, fixture_from_tests, ): fixture_from_main.params_navigation() fixture_from_tests.params_navigation() def test_with_method_definition( fixture_from_main, fixture_from_tests ): fixture_from_main.params_navigation() fixture_from_tests.params_navigation() # File: tests/conftest.py import pytest from pages.home_page import HomePage @pytest.fixture def fixture_from_tests() -> HomePage: return HomePage() # File: tests/conftest.py import pytest from pages.home_page import HomePage @pytest.fixture def fixture_from_main() -> HomePage: return HomePage() # File: test_file_main.py class TestClassTest: def test_without_method_definition( self, fixture_from_main, ): fixture_from_main.params_navigation() def test_with_method_definition(fixture_from_main): fixture_from_main.params_navigation()
Note that the HomePage class is initialized by a fixture in the conftest.py file and passed to the test functions.
The "Go to Definition" should navigate to the params_navigation method definition in home_page.py.
No navigation occurs.
The text was updated successfully, but these errors were encountered:
Thanks for the issue.
Do you have this enabled?
Because this works for me:
Sorry, something went wrong.
Sorry misunderstood. It's not working in the test class, but it is in the test method.
rchiodo
No branches or pull requests
Environment data
Code Snippet
Note that the HomePage class is initialized by a fixture in the conftest.py file and passed to the test functions.
Repro Steps
Expected behavior
The "Go to Definition" should navigate to the params_navigation method definition in home_page.py.
Actual behavior
No navigation occurs.
The text was updated successfully, but these errors were encountered: