Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-53502: Fixes for tests in gh-113363#113627

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
Merged
Changes from1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
NextNext commit
gh-53502: Fixes for tests ingh-113363
1. Use 32-bit compatible date in test_dump_naive_datetime_with_aware_datetime_option2. test_dump_naive_datetime_with_aware_datetime_option: Writing non-aware datetimes   with aware_datetime==True leads to the time being off by twice   the timezone offset from UTC
  • Loading branch information
@ronaldoussoren
ronaldoussoren committedJan 1, 2024
commit6d6263095596ec959f79d130d24fa2e21f8b8209
4 changes: 2 additions & 2 deletionsLib/test/test_plistlib.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -881,11 +881,11 @@ def test_dump_naive_datetime_with_aware_datetime_option(self):
# Save a naive datetime with aware_datetime set to true. This will lead
# to having different time as compared to the current machine's
# timezone, which is UTC.
dt = datetime.datetime(2345, 6, 7, 8, tzinfo=None)
dt = datetime.datetime(2003, 6, 7, 8, tzinfo=None)
for fmt in ALL_FORMATS:
s = plistlib.dumps(dt, fmt=fmt, aware_datetime=True)
parsed = plistlib.loads(s, aware_datetime=False)
expected = dt + datetime.timedelta(seconds=time.timezone)
expected = dt +2 *datetime.timedelta(seconds=time.timezone)
self.assertEqual(parsed, expected)


Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp