SD-M2d: the checker's tag-wanted names the pull request's branch
The lead's ruling of 13:0x: the builder removes the tag when the branch ends, so it needs the branch. Claude-Session: https://claude.ai/code/session_01JG73KJNrH5EgFXMKKYSrig
This commit is contained in:
@@ -98,6 +98,8 @@ type VerdictHolderEvent struct {
|
||||
|
||||
// TagWantedHolderEvent is the body of the holder's event tag-wanted.
|
||||
type TagWantedHolderEvent struct {
|
||||
// the pull request's branch: its tag is removed when the branch ends
|
||||
Branch string `json:"branch"`
|
||||
// its head
|
||||
Head string `json:"head"`
|
||||
// the group member
|
||||
|
||||
@@ -19,7 +19,7 @@ func TestFixtures(t *testing.T) {
|
||||
}{
|
||||
{name: "verdict on the checker's own family", subject: "mesh.mod.mesh-delivery-checker.event.verdict", given: "{\"head\":\"cccccccccccccccccccccccccccccccccccccccc\",\"out-of-step\":[\"go/seats/meshbroker/contract.go\"],\"pull\":3,\"repository\":\"novox/mesh-contracts\",\"verdict\":\"fail\"}", wire: "{\"head\":\"cccccccccccccccccccccccccccccccccccccccc\",\"out-of-step\":[\"go/seats/meshbroker/contract.go\"],\"pull\":3,\"repository\":\"novox/mesh-contracts\",\"verdict\":\"fail\"}",
|
||||
decode: func(b []byte) (any, error) { var v VerdictHolderEvent; err := json.Unmarshal(b, &v); return v, err }, subjectIs: regexp.MustCompile("^mesh\\.mod\\.[a-z0-9-]+\\.event\\.verdict$")},
|
||||
{name: "tag-wanted on the checker's own family", subject: "mesh.mod.mesh-delivery-checker.event.tag-wanted", given: "{\"head\":\"cccccccccccccccccccccccccccccccccccccccc\",\"module\":\"mesh-sdk\",\"package\":\"go\",\"pull\":170,\"repository\":\"novox/mesh-sdk\",\"tag\":\"registry-1966\"}", wire: "{\"head\":\"cccccccccccccccccccccccccccccccccccccccc\",\"module\":\"mesh-sdk\",\"package\":\"go\",\"pull\":170,\"repository\":\"novox/mesh-sdk\",\"tag\":\"registry-1966\"}",
|
||||
{name: "tag-wanted on the checker's own family", subject: "mesh.mod.mesh-delivery-checker.event.tag-wanted", given: "{\"branch\":\"feat/registry\",\"head\":\"cccccccccccccccccccccccccccccccccccccccc\",\"module\":\"mesh-sdk\",\"package\":\"go\",\"pull\":170,\"repository\":\"novox/mesh-sdk\",\"tag\":\"registry-1966\"}", wire: "{\"branch\":\"feat/registry\",\"head\":\"cccccccccccccccccccccccccccccccccccccccc\",\"module\":\"mesh-sdk\",\"package\":\"go\",\"pull\":170,\"repository\":\"novox/mesh-sdk\",\"tag\":\"registry-1966\"}",
|
||||
decode: func(b []byte) (any, error) { var v TagWantedHolderEvent; err := json.Unmarshal(b, &v); return v, err }, subjectIs: regexp.MustCompile("^mesh\\.mod\\.[a-z0-9-]+\\.event\\.tag-wanted$")},
|
||||
{name: "preview.written on the checker's stream", subject: "mesh.mod.mesh-delivery-checker.event.preview.written", given: "{}", wire: "{}",
|
||||
decode: func(b []byte) (any, error) { var v map[string]any; err := json.Unmarshal(b, &v); return v, err }, subjectIs: regexp.MustCompile("^mesh\\.mod\\.[a-z0-9-]+\\.event\\.preview\\.written$")},
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
"repository": "novox/mesh-sdk",
|
||||
"pull": 170,
|
||||
"head": "cccccccccccccccccccccccccccccccccccccccc",
|
||||
"branch": "feat/registry",
|
||||
"module": "mesh-sdk",
|
||||
"package": "go",
|
||||
"tag": "registry-1966"
|
||||
|
||||
@@ -179,6 +179,10 @@
|
||||
"type": "string",
|
||||
"description": "its head"
|
||||
},
|
||||
"branch": {
|
||||
"type": "string",
|
||||
"description": "the pull request's branch: its tag is removed when the branch ends"
|
||||
},
|
||||
"module": {
|
||||
"type": "string",
|
||||
"description": "the group member"
|
||||
@@ -195,6 +199,7 @@
|
||||
"required": [
|
||||
"repository",
|
||||
"head",
|
||||
"branch",
|
||||
"module",
|
||||
"package"
|
||||
]
|
||||
|
||||
@@ -91,6 +91,8 @@ export interface VerdictHolderEvent {
|
||||
|
||||
/** is the body of the holder's event tag-wanted. */
|
||||
export interface TagWantedHolderEvent {
|
||||
/** the pull request's branch: its tag is removed when the branch ends */
|
||||
"branch": string;
|
||||
/** its head */
|
||||
"head": string;
|
||||
/** the group member */
|
||||
|
||||
Reference in New Issue
Block a user