diff --git a/AGENTS.md b/AGENTS.md index 26508cc..802dff2 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -242,8 +242,7 @@ releases. This is the flow CI runs (§9.4). `crafter-build test` runs the nine suites. Each suite is a plain `main()` with a `Check(bool, message)` counter: failures print `FAIL: …`, success prints `: all tests passed`, and the exit status is -the failure count for six suites — non-zero short of a multiple of 256 — and -1 for `Engine`, `Sip` and `Sms`. `crafter-build test` ending in `9 passed`, on every +1 after any failure. `crafter-build test` ending in `9 passed`, on every commit of a range (§11), is the project's definition of green. What the suites pin: diff --git a/tests/Aka/main.cpp b/tests/Aka/main.cpp index e0380cb..49c8d1f 100644 --- a/tests/Aka/main.cpp +++ b/tests/Aka/main.cpp @@ -145,5 +145,5 @@ int main() { } if (Failures == 0) std::println("Aka: all tests passed"); - return Failures; + return Failures != 0; // not the count: `crafter-build test` takes an exit status of 77 for a skipped suite, and an exit status keeps 8 bits } diff --git a/tests/Ipsec/main.cpp b/tests/Ipsec/main.cpp index 07f24c4..d8e3088 100644 --- a/tests/Ipsec/main.cpp +++ b/tests/Ipsec/main.cpp @@ -374,5 +374,5 @@ int main() { } if (Failures == 0) std::println("Ipsec: all tests passed"); - return Failures; + return Failures != 0; // not the count: `crafter-build test` takes an exit status of 77 for a skipped suite, and an exit status keeps 8 bits } diff --git a/tests/Messages/main.cpp b/tests/Messages/main.cpp index 2dccd9a..519ed15 100644 --- a/tests/Messages/main.cpp +++ b/tests/Messages/main.cpp @@ -512,5 +512,5 @@ int main() { } if (Failures == 0) std::println("Messages: all tests passed"); - return Failures; + return Failures != 0; // not the count: `crafter-build test` takes an exit status of 77 for a skipped suite, and an exit status keeps 8 bits } diff --git a/tests/Qmi/main.cpp b/tests/Qmi/main.cpp index 111a07d..245a116 100644 --- a/tests/Qmi/main.cpp +++ b/tests/Qmi/main.cpp @@ -90,5 +90,5 @@ int main() { } if (Failures == 0) std::println("Qmi: all tests passed"); - return Failures; + return Failures != 0; // not the count: `crafter-build test` takes an exit status of 77 for a skipped suite, and an exit status keeps 8 bits } diff --git a/tests/Sdp/main.cpp b/tests/Sdp/main.cpp index a29148b..ed3fa19 100644 --- a/tests/Sdp/main.cpp +++ b/tests/Sdp/main.cpp @@ -396,5 +396,5 @@ int main() { } if (Failures == 0) std::println("Sdp: all tests passed"); - return Failures; + return Failures != 0; // not the count: `crafter-build test` takes an exit status of 77 for a skipped suite, and an exit status keeps 8 bits } diff --git a/tests/Util/main.cpp b/tests/Util/main.cpp index 7b4f5f7..ae86762 100644 --- a/tests/Util/main.cpp +++ b/tests/Util/main.cpp @@ -137,5 +137,5 @@ int main() { } if (Failures == 0) std::println("Util: all tests passed"); - return Failures; + return Failures != 0; // not the count: `crafter-build test` takes an exit status of 77 for a skipped suite, and an exit status keeps 8 bits }