Skip to content

Check core tests with pyright - #4418

Merged
r4victor merged 8 commits into
masterfrom
pr_pyright_core_tests
Oct 28, 2026
Merged

r4victor merged 8 commits into
masterfrom
pr_pyright_core_tests

Conversation

@r4victor

Copy link
Copy Markdown
Collaborator
  • Check src/tests/_internal/core with pyright.
  • Add IncludeExcludeStrDictType and use it for the core/compatibility excludes, which are always keyed by field names; nested values can still be keyed by int.
  • Make the backend tests' _compute_with_mocked_api_client() helpers return the mocked API client, so tests configure a MagicMock rather than the typed client attribute.
  • Use model_validate() for shorthand test inputs like ResourcesSpec(disk="100GB.."), and construct expected values directly so the parser isn't tested against itself.
  • Build real offers and instance configurations in the verda tests instead of SimpleNamespace fakes.
  • Narrow union and optional results in tests with isinstance and is not None asserts.
  • Pass Requirements instead of None to get_offers_by_requirements() in the seeweb tests.

@r4victor
r4victor merged commit 43874b1 into master Oct 28, 2026
56 of 58 checks passed
@r4victor
r4victor deleted the pr_pyright_core_tests branch October 28, 2026 06:35
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

Successfully merging this pull request may close these issues.

1 participant