Skip to content
New issue

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

Tests fail: TypeError: Test file has to be YAML list, got <class 'dict'>. #197

Open
yurivict opened this issue Nov 15, 2024 · 1 comment

Comments

@yurivict
Copy link
Contributor

_______________________________________________________ ERROR collecting test/cassettes/test-works/test_works_with_select_param.yaml ________________________________________________________
/usr/local/lib/python3.11/site-packages/pytest_mypy_plugins/collect.py:117: in collect
    validate_schema(parsed_file, is_closed=self.config.option.mypy_closed_schema)
/usr/local/lib/python3.11/site-packages/pytest_mypy_plugins/collect.py:45: in validate_schema
    raise TypeError(f"Test file has to be YAML list, got {type(data)!r}.")
E   TypeError: Test file has to be YAML list, got <class 'dict'>.
_______________________________________________ ERROR collecting test/cassettes/test-workscontainer/test_workscontainer_failure_behavior.yaml _______________________________________________
/usr/local/lib/python3.11/site-packages/pytest_mypy_plugins/collect.py:117: in collect
    validate_schema(parsed_file, is_closed=self.config.option.mypy_closed_schema)
/usr/local/lib/python3.11/site-packages/pytest_mypy_plugins/collect.py:45: in validate_schema
    raise TypeError(f"Test file has to be YAML list, got {type(data)!r}.")
E   TypeError: Test file has to be YAML list, got <class 'dict'>.
_________________________________________________ ERROR collecting test/cassettes/test-workscontainer/test_workscontainer_with_cursor.yaml __________________________________________________
/usr/local/lib/python3.11/site-packages/pytest_mypy_plugins/collect.py:117: in collect
    validate_schema(parsed_file, is_closed=self.config.option.mypy_closed_schema)
/usr/local/lib/python3.11/site-packages/pytest_mypy_plugins/collect.py:45: in validate_schema
    raise TypeError(f"Test file has to be YAML list, got {type(data)!r}.")
E   TypeError: Test file has to be YAML list, got <class 'dict'>.
__________________________________________________ ERROR collecting test/cassettes/test-workscontainer/test_workscontainer_with_many.yaml ___________________________________________________
/usr/local/lib/python3.11/site-packages/pytest_mypy_plugins/collect.py:117: in collect
    validate_schema(parsed_file, is_closed=self.config.option.mypy_closed_schema)
/usr/local/lib/python3.11/site-packages/pytest_mypy_plugins/collect.py:45: in validate_schema
    raise TypeError(f"Test file has to be YAML list, got {type(data)!r}.")
E   TypeError: Test file has to be YAML list, got <class 'dict'>.

Version: 1.2.6
Python-3.11
FreeBSD 14.1

@sckott
Copy link
Owner

sckott commented Nov 15, 2024

Thanks for reporting. I'll have a look

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants