Bug 232197

Summary: [webkitscmpy] Log based tests fail in different timezones
Product: WebKit Reporter: Aakash Jain <aakash_jain>
Component: Tools / TestsAssignee: Jonathan Bedard <jbedard>
Status: RESOLVED FIXED    
Severity: Normal CC: aakash_jain, dewei_zhu, ryanhaddad, slewis, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Other   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=218079
https://bugs.webkit.org/show_bug.cgi?id=225741
Attachments:
Description Flags
Patch
none
Patch none

Aakash Jain
Reported 2021-10-23 06:56:24 PDT
Few webkitpy unit-tests fail when run in different time zone. e.g.: [1466/2023] webkitscmpy.test.log_unittest.TestLog.test_git_svn_revision failed: Traceback (most recent call last): File "Tools/Scripts/libraries/webkitscmpy/webkitscmpy/test/log_unittest.py", line 134, in test_git_svn_revision self.assertEqual( AssertionError: 'comm[118 chars] 03 00:46:40 2020 +0000\n\n Patch Series\n [1203 chars]fc\n' != 'comm[118 chars] 03 03:46:40 2020 +0000\n\n Patch Series\n [1203 chars]fc\n' commit r9 (d8bce26fa65c6fc8f39c17927abb77f69fab82fc, 5@main) Author: Jonathan Bedard <jbedard@apple.com> - Date: Sat Oct 03 00:46:40 2020 +0000 ? ^ + Date: Sat Oct 03 03:46:40 2020 +0000 ? ^ Patch Series git-svn-id: https://svn.example.org/repository/repository/trunk@9 268f45cc-cd09-0410-ab3c-d52691b4dbfc commit r8 (bae5d1e90999d4f916a8a15810ccfa43f37a2fd6, 4@main) Author: Jonathan Bedard <jbedard@apple.com> - Date: Sat Oct 03 00:46:40 2020 +0000 ? ^ + Date: Sat Oct 03 03:46:40 2020 +0000 ? ^ AssertionError: 'comm[118 chars] 03 00:46:40 2020 +0000\n\n Patch Series\n [1203 chars]fc\n' != 'comm[118 chars] 03 03:46:40 2020 +0000\n\n Patch Series\n [1203 chars]fc\n' commit r9 (d8bce26fa65c6fc8f39c17927abb77f69fab82fc, 5@main) Author: Jonathan Bedard <jbedard@apple.com> - Date: Sat Oct 03 00:46:40 2020 +0000 ? ^ + Date: Sat Oct 03 03:46:40 2020 +0000 ? ^ Patch Series git-svn-id: https://svn.example.org/repository/repository/trunk@9 268f45cc-cd09-0410-ab3c-d52691b4dbfc commit r8 (bae5d1e90999d4f916a8a15810ccfa43f37a2fd6, 4@main) Author: Jonathan Bedard <jbedard@apple.com> - Date: Sat Oct 03 00:46:40 2020 +0000 ? ^ + Date: Sat Oct 03 03:46:40 2020 +0000 ? ^ 8th commit git-svn-id: https://svn.example.org/repository/repository/trunk@8 268f45cc-cd09-0410-ab3c-d52691b4dbfc commit r4 (1abe25b443e985f93b90d830e4a7e3731336af4d, 3@main) Author: Jonathan Bedard <jbedard@apple.com> - Date: Fri Oct 02 23:23:20 2020 +0000 ? ^^^ --- + Date: Sat Oct 03 02:23:20 2020 +0000 ? ^^^ +++ 4th commit git-svn-id: https://svn.example.org/repository/repository/trunk@4 268f45cc-cd09-0410-ab3c-d52691b4dbfc commit r2 (fff83bb2d9171b4d9196e977eb0508fd57e7a08d, 2@main) Author: Jonathan Bedard <jbedard@apple.com> - Date: Fri Oct 02 22:50:00 2020 +0000 ? ^^^ ^^^^ + Date: Sat Oct 03 01:50:00 2020 +0000 ? ^^^ ^^^^ 2nd commit git-svn-id: https://svn.example.org/repository/repository/trunk@2 268f45cc-cd09-0410-ab3c-d52691b4dbfc commit r1 (9b8311f25a77ba14923d9d5a6532103f54abefcb, 1@main) Author: Jonathan Bedard <jbedard@apple.com> - Date: Fri Oct 02 22:33:20 2020 +0000 ? ^^^ ^^^^ + Date: Sat Oct 03 01:33:20 2020 +0000 ? ^^^ ^^^^ 1st commit git-svn-id: https://svn.example.org/repository/repository/trunk@1 268f45cc-cd09-0410-ab3c-d52691b4dbfc [1657/2023] webkitscmpy.test.log_unittest.TestLog.test_git_svn failed: Traceback (most recent call last): File "Tools/Scripts/libraries/webkitscmpy/webkitscmpy/test/log_unittest.py", line 87, in test_git_svn self.assertEqual( AssertionError: 'comm[118 chars] 03 00:46:40 2020 +0000\n\n Patch Series\n [1203 chars]fc\n' != 'comm[118 chars] 03 03:46:40 2020 +0000\n\n Patch Series\n [1203 chars]fc\n' Diff is 1853 characters long. Set self.maxDiff to None to see it.
Attachments
Patch (10.94 KB, patch)
2021-10-25 08:44 PDT, Jonathan Bedard
no flags
Patch (10.64 KB, patch)
2021-10-25 08:46 PDT, Jonathan Bedard
no flags
Radar WebKit Bug Importer
Comment 1 2021-10-25 08:43:38 PDT
Jonathan Bedard
Comment 2 2021-10-25 08:44:53 PDT
Jonathan Bedard
Comment 3 2021-10-25 08:46:54 PDT
Jonathan Bedard
Comment 4 2021-10-25 08:47:43 PDT
All of these are basically the exact same problem: When we match `git log` output in unit tests, we need to be timezone-aware.
dewei_zhu
Comment 5 2021-10-25 10:09:10 PDT
Comment on attachment 442375 [details] Patch r=me
EWS
Comment 6 2021-10-25 10:40:19 PDT
Committed r284791 (243500@main): <https://commits.webkit.org/243500@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 442375 [details].
Note You need to log in before you can comment on or make changes to this bug.