Skip to content

fix broken tests#200

Merged
sebpretzer merged 2 commits into
mainfrom
fix_broken_tests
Nov 27, 2025
Merged

fix broken tests#200
sebpretzer merged 2 commits into
mainfrom
fix_broken_tests

Conversation

@sebpretzer
Copy link
Copy Markdown
Owner

This just fixes existing tests as the API has changed. This does not include new functionality.

Copilot AI review requested due to automatic review settings November 27, 2025 20:20
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes broken integration tests after an API change. The main updates are adding timezone-aware datetime handling for completed tasks and new unknown fields in model classes.

  • Imports UTC timezone for proper datetime handling
  • Adds completed_time field with UTC timezone to test task data
  • Adds background field placeholder to ProjectV2 and ProjectGroupV2 models

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
tests/integration/v2/test_closed.py Imports UTC and adds completed_time with UTC timezone to task test data
src/pyticktick/models/v2/models.py Adds background field placeholder to ProjectV2 and ProjectGroupV2 models

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

)

# unknown fields
background: None
Copy link

Copilot AI Nov 27, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The background field lacks a type annotation. Consider using background: None = None to properly type hint this as an optional field that defaults to None, or background: Optional[str] = None if it should accept string values.

Copilot uses AI. Check for mistakes.
)

# unknown fields
background: None
Copy link

Copilot AI Nov 27, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The background field lacks a type annotation. Consider using background: None = None to properly type hint this as an optional field that defaults to None, or background: Optional[str] = None if it should accept string values.

Copilot uses AI. Check for mistakes.
@github-actions
Copy link
Copy Markdown
Contributor

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  src/pyticktick/models/v2
  models.py
Project Total  

This report was generated by python-coverage-comment-action

@sebpretzer sebpretzer merged commit 2811585 into main Nov 27, 2025
11 checks passed
@sebpretzer sebpretzer deleted the fix_broken_tests branch November 27, 2025 20:27
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.

2 participants