A coverage map of the base: lib_value runs only under alpha_uses_lib, * lib_other only under matrix_one; every setup row is complete and empty. */
| 355 | /* A coverage map of the base: lib_value runs only under alpha_uses_lib, |
| 356 | * lib_other only under matrix_one; every setup row is complete and empty. */ |
| 357 | static bool tie_coverage(tie_fixture_t *fx, const char *sha, char *dir, size_t cap) { |
| 358 | snprintf(dir, cap, "%s/coverage", fx->home); |
| 359 | char meta[1024]; |
| 360 | snprintf(meta, sizeof(meta), |
| 361 | "{\"format\":1,\"commit\":\"%s\",\"functions\":2,\"tests\":4," |
| 362 | "\"incomplete\":0,\"platform\":\"fixture\",\"llvm_profdata\":\"fixture\"," |
| 363 | "\"suites\":[{\"suite\":\"alpha\",\"tests\":2,\"incomplete\":0,\"exit\":0}," |
| 364 | "{\"suite\":\"beta\",\"tests\":1,\"incomplete\":0,\"exit\":0}," |
| 365 | "{\"suite\":\"matrix\",\"tests\":1,\"incomplete\":0,\"exit\":0}]}\n", |
| 366 | sha); |
| 367 | return th_mkdir_p(dir) == 0 && |
| 368 | th_write_file(TH_PATH(dir, "functions.tsv"), |
| 369 | "0\tsrc/lib.c\tlib_value\n1\tsrc/lib.c\tlib_other\n") == 0 && |
| 370 | th_write_file(TH_PATH(dir, "tests.tsv"), |
| 371 | "alpha:*\tcomplete\t\t\nalpha:alpha_plain\tcomplete\t\t\n" |
| 372 | "alpha:alpha_uses_lib\tcomplete\t\t0\nbeta:*\tcomplete\t\t\n" |
| 373 | "beta:beta_alone\tcomplete\t\t\nmatrix:*\tcomplete\t\t\n" |
| 374 | "matrix:matrix_one\tcomplete\t\t1\n") == 0 && |
| 375 | th_write_file(TH_PATH(dir, "meta.json"), meta) == 0; |
| 376 | } |
| 377 | |
| 378 | /* The team artifact: the merge base's bundle, verified by the caller, is the |
| 379 | * graph base and its admitted map narrows a suite to the tests that ran the |
no test coverage detected