(self, stderr, target, required)
| 203 | return numbers |
| 204 | |
| 205 | def errors(self, stderr, target, required): |
| 206 | native, owned = [], [] |
| 207 | for line in stderr.splitlines(): |
| 208 | if line.startswith("LLVM Profile Error:"): |
| 209 | match = re.fullmatch(r'LLVM Profile Error: Failed to write file "(.*)": (.+)', line) |
| 210 | require(match is not None and match.group(1) == str(target), |
| 211 | "unrecognized or wrong-path native LLVM error") |
| 212 | native.append({"line": line, "reason": match.group(2)}) |
| 213 | elif line.startswith("coverage profile write failed:"): |
| 214 | require(line == "coverage profile write failed: " + str(target), |
| 215 | "wrong-path runner-owned profile failure") |
| 216 | owned.append(line) |
| 217 | elif (line.startswith("coverage child accounting ") |
| 218 | or line.startswith("coverage profile could not be routed:") |
| 219 | or line.startswith("a coverage run starts with") |
| 220 | or line.startswith("cannot use coverage directory:") |
| 221 | or line.startswith("cannot route coverage profiles under:")): |
| 222 | raise Infrastructure("unrelated coverage activation/accounting failure") |
| 223 | require(bool(native) == required, "intended native terminal-write precondition not observed") |
| 224 | require(len(owned) <= 1, "duplicate runner-owned final failure") |
| 225 | if not required: |
| 226 | require(not owned, "positive control reported final writer failure") |
| 227 | return {"native": native, "runner_owned": owned} |
| 228 | |
| 229 | def case(self, mode, source_seed=None): |
| 230 | case = self.root / mode |
no test coverage detected