Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: bc35cc462465e305e36faed733769a295f162d2a
      
https://github.com/WebKit/WebKit/commit/bc35cc462465e305e36faed733769a295f162d2a
  Author: Sam Sneddon <[email protected]>
  Date:   2026-06-05 (Fri, 05 Jun 2026)

  Changed paths:
    M Tools/Scripts/libraries/webkitscmpy/webkitscmpy/mocks/local/git.py
    M Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/command.py
    A Tools/Scripts/libraries/webkitscmpy/webkitscmpy/test/command_unittest.py

  Log Message:
  -----------
  git-webkit log --hash rewrites too much
https://bugs.webkit.org/show_bug.cgi?id=301470
rdar://163410883

Reviewed by Elliott Williams.

This fixes some regexes and adds a load of tests.

* Tools/Scripts/libraries/webkitscmpy/webkitscmpy/mocks/local/git.py: Add more 
mocks for git log.
* Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/command.py:
(FilteredCommand.GIT_HEADER_RE): Avoid matching all lines which start with hex 
characters (e.g. "Date").
(FilteredCommand.IDENTIFIER_RES): The first subpattern needs to be 
non-capturing, as otherwise it is used as the replacement.
(FilteredCommand.main.replace_line): Handle the various types of replacement in 
deterministic order.
* Tools/Scripts/libraries/webkitscmpy/webkitscmpy/test/command_unittest.py: 
Added.
(TestFilteredCommandBase):
(TestFilteredCommandBase.representation):
(TestFilteredCommandBase.setUp):
(TestFilteredCommandBase._run_log):
(TestFilteredCommandHash):
(TestFilteredCommandHash.test_output):
(TestFilteredCommandHash.test_abbrev_commit):
(TestFilteredCommandHash.test_oneline):
(TestFilteredCommandHash.test_decorate):
(TestFilteredCommandHash.test_decorate_multiple_branches):
(TestFilteredCommandHash.test_decorate_non_tip_commit):
(TestFilteredCommandHash.test_identifier_in_body_transformed):
(TestFilteredCommandHash.test_hash_in_body_not_transformed):
(TestFilteredCommandHash.test_revision_in_body_transformed):
(TestFilteredCommandHash.test_canonical_link_space_not_transformed):
(TestFilteredCommandHash.test_git_svn_id_not_transformed):
(TestFilteredCommandIdentifier):
(TestFilteredCommandIdentifier.test_output):
(TestFilteredCommandIdentifier.test_hash_in_body_transformed):
(TestFilteredCommandIdentifier.test_identifier_in_body_not_transformed):
(TestFilteredCommandIdentifier.test_revision_in_body_transformed):
(TestFilteredCommandRevision):
(TestFilteredCommandRevision.test_output):
(TestFilteredCommandRevision.test_identifier_in_body_transformed):
(TestFilteredCommandRevision.test_hash_in_body_transformed):
(TestFilteredCommandRevision.test_revision_in_body_not_transformed):

Canonical link: https://commits.webkit.org/314676@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to