[webkit-changes] [WebKit/WebKit] 375f0a: Fix `test-webkitpy webkitflaskpy`

Sam Sneddon noreply at github.com
Wed Sep 6 12:00:28 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 375f0a128550381f809ffad568989797289dda60
      https://github.com/WebKit/WebKit/commit/375f0a128550381f809ffad568989797289dda60
  Author: Sam Sneddon <gsnedders at apple.com>
  Date:   2023-09-06 (Wed, 06 Sep 2023)

  Changed paths:
    M Tools/Scripts/webkitpy/test/finder.py
    M Tools/Scripts/webkitpy/test/finder_unittest.py
    M Tools/Scripts/webkitpy/test/main.py

  Log Message:
  -----------
  Fix `test-webkitpy webkitflaskpy`
https://bugs.webkit.org/show_bug.cgi?id=261108

Reviewed by Jonathan Bedard.

webkitpy.test.finder.DirectoryTree.subpath used to consider everything except
for absolute paths as subpaths, and as such everything was always found as a
subtree of the first tree. This is clearly incorrect. Instead, require it
actually start with the name of the package described by the tree.

While we're at it, make `starting_directory` required everywhere: the only place
where it was previously None was in finder_unittest, which isn't helpful.

* Tools/Scripts/webkitpy/test/finder.py:
(_DirectoryTree.__init__):
(_DirectoryTree.subpath):
(Finder.add_tree):
* Tools/Scripts/webkitpy/test/finder_unittest.py:
(FinderTest.setUp):
(FinderTest.test_additional_system_paths):
(FinderTest.test_default_names):
(FinderTest.test_paths):
* Tools/Scripts/webkitpy/test/main.py:
(Tester.add_tree):

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




More information about the webkit-changes mailing list