MCPcopy Create free account
hub / github.com/commonhaus/foundation / CodeownersCheck

Class CodeownersCheck

templates/panda/PolicyPanda.java:571–599  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

569 }
570
571 record CodeownersCheck(CodeOwnerError[] errors, GHContent content)
572 implements Information {
573 public String summary() {
574 // formatter:off
575 return "- %s Codeowners - %s%s%s".formatted(
576 (ok() ? "💚" : "❌"),
577 (ok() ? "File is valid" : "File has errors"),
578 Stream.of(errors)
579 .map(CodeOwnerError::summary)
580 .collect(Collectors.joining("")),
581 urlText(content));
582 // formatter:on
583 }
584
585 public String markdownSummary() {
586 return "- [%s] %s Codeowners - %s%s%s".formatted(
587 (ok() ? "x" : " "),
588 (ok() ? "💚" : "❌"),
589 (ok() ? "File is valid" : "File has errors"),
590 Stream.of(errors)
591 .map(CodeOwnerError::markdownSummary)
592 .collect(Collectors.joining("")),
593 urlText(content)).replace(" \n", "\n");
594 }
595
596 boolean ok() {
597 return errors == null || errors.length == 0;
598 }
599 }
600
601 record ContentCheck(String name, String description, Kind kind, boolean ok, GHContent content)
602 implements Information {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…