I'd value a second set of eyes on this. It saves about 40 lines or so (the savings would be bigger if we were ignoring copyright header comments), but:
I believe these changes might make it harder to convert these tools back to detectors if we ever decided to do so.
The savings come from additional abstraction, which might hurt readability.
(This pr is focused on the code sharing change, which is on a branch off the add-bazel branch. There will be a later pr to cover the addition of bazel.)
Coverage increased (+0.1%) to 30.519% when pulling ce16394d768372a23bdbec5f9644ef1c1dc95732 on sb_ToolSupport into a0ad225cbaeb7ad6d92fc07b2f8debbb9bb5f596 on sb_bazelDetector.
I'd value a second set of eyes on this. It saves about 40 lines or so (the savings would be bigger if we were ignoring copyright header comments), but:
(This pr is focused on the code sharing change, which is on a branch off the add-bazel branch. There will be a later pr to cover the addition of bazel.)