aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrancois Kritzinger <francois@codesynthesis.com>2024-04-17 08:35:50 +0200
committerFrancois Kritzinger <francois@codesynthesis.com>2024-04-24 15:16:14 +0200
commitbff60002c9cd2b5881bce1bb521364f84af00cb4 (patch)
treebcbae146ba00a936dba5eb3f470d90438e09d3e7
parent29086996ada51bf501ba605ed412b49fa6fece00 (diff)
Rename queue_check_runs() to create_check_runs()
-rw-r--r--mod/mod-ci-github.cxx13
1 files changed, 7 insertions, 6 deletions
diff --git a/mod/mod-ci-github.cxx b/mod/mod-ci-github.cxx
index 95aa822..bb174cf 100644
--- a/mod/mod-ci-github.cxx
+++ b/mod/mod-ci-github.cxx
@@ -612,10 +612,11 @@ namespace brep
// Serialize `createCheckRun` mutations for one or more builds to GraphQL.
//
static string
- queue_check_runs (const string& ri, // Repository ID
- const string& hs, // Head SHA
- const vector<reference_wrapper<const build>>& bs,
- const build_queued_hints* bqh)
+ create_check_runs (const string& ri, // Repository ID
+ const string& hs, // Head SHA
+ const vector<reference_wrapper<const build>>& bs,
+ build_state st,
+ const tenant_service_base::build_hints* bh = nullptr)
{
ostringstream os;
@@ -631,13 +632,13 @@ namespace brep
// Check run name.
//
- string nm (check_run_name (b, bqh));
+ string nm (check_run_name (b, bh));
os << gq_name (al) << ":createCheckRun(input: {" << '\n'
<< " name: " << gq_str (nm) << ',' << '\n'
<< " repositoryId: " << gq_str (ri) << ',' << '\n'
<< " headSha: " << gq_str (hs) << ',' << '\n'
- << " status: " << gq_enum ("QUEUED") << '\n'
+ << " status: " << gq_enum (to_string_gh (st)) << '\n'
<< "})" << '\n'
// Specify the selection set (fields to be returned).
//