MCPcopy Index your code
hub / github.com/nodejs/node / SetupReportGroups

Function SetupReportGroups

deps/v8/tools/locs.py:224–258  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

222
223
224def SetupReportGroups():
225 default_report_groups = {"total": '.*',
226 "src": '\\.\\./\\.\\./src',
227 "test": '\\.\\./\\.\\./test',
228 "third_party": '\\.\\./\\.\\./third_party',
229 "gen": 'gen'}
230
231 report_groups = default_report_groups.copy()
232 report_groups.update(dict(ARGS['group']))
233
234 if ARGS['only']:
235 for only_arg in ARGS['only']:
236 if not only_arg in report_groups.keys():
237 print("Error: specified report group '{}' is not defined.".format(
238 ARGS['only']))
239 exit(1)
240 else:
241 report_groups = {
242 k: v for (k, v) in report_groups.items() if k in ARGS['only']}
243
244 if ARGS['not']:
245 report_groups = {
246 k: v for (k, v) in report_groups.items() if k not in ARGS['not']}
247
248 if ARGS['list_groups']:
249 print_cat_max_width = MaxWidth(list(report_groups.keys()) + ["Category"])
250 print(" {:<{}} {}".format("Category",
251 print_cat_max_width, "Regular expression"))
252 for cat, regexp_string in report_groups.items():
253 print(" {:<{}}: {}".format(
254 cat, print_cat_max_width, regexp_string))
255
256 report_groups = {k: Group(k, v) for (k, v) in report_groups.items()}
257
258 return report_groups
259
260
261class Results:

Callers 1

__init__Method · 0.85

Calls 10

MaxWidthFunction · 0.85
printFunction · 0.70
GroupClass · 0.70
copyMethod · 0.65
updateMethod · 0.65
keysMethod · 0.65
formatMethod · 0.65
exitFunction · 0.50
listFunction · 0.50
itemsMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…