Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
132 changes: 132 additions & 0 deletions .agents/docs/2026-11-21-mtest-doctest-adapter-design.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,132 @@
---
subject: tests
status: active
---

# doctest 测试接入 mtest 协议:改用上游适配器 `mcpplibs.mtest.doctest`

> 日期:2026-11-21 · mcpp 2026.11.20.1 · mtest 0.11.1 · doctest 2.4.12
>
> 来源:[mcpplibs/boost-m#7](https://github.com/mcpplibs/boost-m/issues/7) 的调查与计划;
> mcpp `docs/specs/test.md`(SPEC-017)B6;mtest 0.11.0(mcpp-community/mtest#26)。

## 0. 结论

#7 计划的第一项"写 doctest 适配器入口包"由上游完成:mtest 0.11.0 发布了
`mcpplibs.mtest.doctest`(L1)。它是入口包(`test-protocol = 1`、`test-main = true`),
doctest 的实现和 `main` 只在包里编译一次,依赖只有 `compat.doctest` 2.4.12 与
`nlohmann.json`,不经过 mtest 库、`mcpplibs.os` 与 openkal。

本仓库直接使用它,不再自写适配器:根包与 `tests/dll` 的 `[dev-dependencies]` 加上
`mcpplibs.mtest.doctest = "0.11.1"`,删去全部 139 处 `DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN`
(含两个移植生成器的模板)。本地(Linux x86_64,gcc 16.1.0)根包 417 个测试程序与
`tests/dll` 的 4 个全部通过;llvm@22.1.8 抽查 6 个受影响最大的文件通过。

[2026-11-09 设计记录](2026-11-09-module-test-hardening-design.md) §4.1 中"每个测试文件
自己定义 `main`"的约定由本记录取代:测试文件只 `#include <doctest/doctest.h>`,不定义
`DOCTEST_CONFIG_IMPLEMENT*`。

## 1. 只能一次全部迁移

mcpp 对待入口包的方式决定了不能逐库试点:

- 适配器包的库源 `src/protocol.cpp`(doctest 实现 + reporter)链接进根包的**每个**测试
程序,包括冒烟测试与 Boost.Test 测试。仍保留 `IMPLEMENT_WITH_MAIN` 的文件因此重复
定义 doctest 的全部符号。
- 入口 `src/main.cpp` 链接进"不定义 `main`"的测试。mcpp 判断这一点靠扫描源文件的
**文本**(`plan.cppm` 的 `source_defines_main`:去掉注释与字面量,按预处理条件取舍,
找 `int main(` / `auto main(`)。由宏或头文件给出 `main` 的文件被判为没有 `main`。

后者涉及 4 个文件:`tests/cobalt/co_main.cpp`(`main` 在 `<boost/cobalt/main.hpp>`)与
Boost.Test 头文件形态的 `tests/test/custom_types.cpp`、`tests/test/included/{smoke,doc_reference}.cpp`
(`main` 在 `<boost/test/included/unit_test.hpp>`;`#ifdef MCPP_FEATURE_UNIT_TEST_FRAMEWORK`
分支里的 `int main()` 被扫描当作不编译)。处理:在文件中写出与头文件相同的声明
`int main(int argc, char* argv[]);`(cobalt 的 `detail/main.hpp:31` 就有同一声明),
Boost.Test 文件写在 `#else` 分支里。

非 doctest 程序链接了 `protocol.o`,但 Linux 上 `--gc-sections` 去掉了其中的
`mtest-protocol=1` 标记(实测 `accumulators`、`asio/smoke`、`test/included/smoke`、
`cobalt/co_main` 中均无)。mcpp 判断协议程序看的是入口声明,不看标记,记录中这些程序的
`protocol` 为 `null`。

## 2. doctest 实现曾替测试提供的 C 头文件

`DOCTEST_CONFIG_IMPLEMENT` 让 doctest.h 包含 `<csignal>`、`<cerrno>`、`<climits>`、
`<cmath>`、`<cstdint>` 等。移植的上游示例原本经由 Boost 头文件得到它们,移植时 Boost
头文件被模块取代,于是一直靠 doctest 实现兜底。删去实现后 11 个文件编译失败:

| 缺少 | 文件 |
|---|---|
| `SIGINT`、`SIGTERM`、`signal` | asio/network_cpp14_cpp20、asio/network_http、beast/examples_websocket、math/examples_2、mqtt5/examples |
| `errno` | json/examples |
| `INT_MAX`、`INT_MIN` | convert/examples_stream(手写) |
| `FP_ZERO` | decimal/api_cmath_io、math/doc_tools(手写) |
| `::sin`、`::cos`、`::floor` | geometry/examples、geometry/examples_algorithms |
| `::uint16_t` | mqtt5/examples |

这些是宏或全局命名空间中的 C 名字,`import std` 不提供。`tools/port_tests/port_examples.py`
新增 `C_NAMES`:`import std` 形态的移植在用例中用到这些名字、而保留的头文件里没有对应头时,
补上 `#include`。已提交的生成文件按同一规则补齐(另有 `asio/network_cpp11` 多得一个
`<cmath>`,无害);`regen.py` 需要发布包与 oracle 构建,本轮未重跑。手写的 3 个文件直接补
`#include`。

## 3. GCC 16:`npos` 的强定义

`asio/custom_types` 与 `geometry/api_reference` 链接时 `std::string::npos` 重复定义,另一方是
`libstdc++.a(string-inst.o)`。这两个翻译单元只 `import std`,`CHECK(s.find(..) != std::string::npos)`
经 doctest 的表达式分解按 `const&` 绑定 `npos`(ODR 使用),GCC 16 为它发出了不在 COMDAT 组
中的 `GLOBAL` 定义(`basic_string<char>` 有显式实例化声明,本不应发出)。以前没有其他目标
文件需要 `string-inst.o`;`protocol.o` 需要,静态 libstdc++ 于是把它拉进来。在文件中文本包含
`<string>` 无效。处理:改写为 `s.contains(..)`(C++23),不再 ODR 使用 `npos`。仓库中另有
14 处同类写法,它们的目标文件没有强定义,未改。

## 4. 覆盖率核对

`tools/ci/test_coverage.py check --listing` 原先从程序输出(`run_output`)解析 doctest 的
`--list-test-cases`。在 mcpp 之下,适配器把 reporter 换成自己的,doctest 列表模式调用它的
`report_query`,用例作为协议的 `case` 事件交给 mcpp,进入记录的 `listed` 字段,输出为空。
`listing_cases` 改为优先读 `listed`(`name` 即 doctest 的用例名,模板实例同样补出模板名)。
CI 的命令不变。对照:旧脚本读新的列表报 1791 处"程序未列出该用例",新脚本通过。

## 5. 实测

**编译时间**(gcc 16.1.0,dev,单线程,同一条编译命令加与不加
`-DDOCTEST_CONFIG_IMPLEMENT_WITH_MAIN`):

| 文件 | 现在 | 原先 | 节省 |
|---|---:|---:|---:|
| algorithm/api_string | 2.32 s | 3.75 s | 1.44 s |
| json/custom_types | 1.65 s | 3.02 s | 1.37 s |
| math/doc_sf | 4.58 s | 6.11 s | 1.53 s |
| asio/api_overview | 9.00 s | 10.57 s | 1.57 s |
| geometry/api_reference | 17.13 s | 18.49 s | 1.35 s |
| core/api | 1.17 s | 2.60 s | 1.43 s |
| beast/doc | 10.70 s | 12.79 s | 2.09 s |
| container/api | 3.17 s | 4.75 s | 1.59 s |

平均每个文件 1.55 s,与 #7 §3 的估计一致;139 个文件约 3.6 分钟 CPU 时间每条 gcc 腿。

**协议**(临时探测程序,未提交):`--cases` 列出用例与位置;`--case` 逐字节选择,含 `*` 与
逗号的名字也正确;失败带文件与行;`--failed` 只重跑失败的用例;用例中 `raise(SIGSEGV)`
时整体运行报到该用例,`--split case` 下其余用例照常运行;`doctest::skip()` 报为跳过,
`may_fail` 通过。asio 已有的 `ex_case_names` 看门狗 listener 与适配器共存。全量运行得到
136 个协议程序、1815 个用例记录。

#7 提到的"`--cases` 把 L0 程序报成失败"在 mcpp 2026.11.20.1 中不再出现(报为
"one case, its exit status")。

## 6. 尚未验证

- windows llvm-msvc 与 arm64 musl 腿:本轮以 CI 为准。Windows 上 lld-link 是否同样去掉
非 doctest 程序中的协议标记也待 CI 观察(不影响 mcpp,只影响独立运行的 mtest 引擎)。
- `regen.py` 重新生成与已提交文件逐字节一致(§2)。

## 7. 上游适配器的缺口(向 mcpp-community/mtest 反馈)

- 同名用例得到相同 ID(P3.2 要求确定的去重):`--case duplicate` 运行两个,`--split case`
合成一个进程。
- 读取后未从环境中清除 `MTEST_*`(P2.2),子进程会继承。
- P3.3 调度提示只映射了 `skip`;`timeout`、`may_fail`、`should_fail`、`expected_failures` 未映射。
- 异常与崩溃的 `failure` 事件 `file` 为空、`line` 为 0。
- 程序在 mcpp 之外运行且设置了 `MTEST_PROTOCOL` 时,doctest 的 `--list-test-cases` 不再打印到
标准输出(本仓库已改为读 `listed`,记此备查)。
5 changes: 4 additions & 1 deletion .agents/docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,12 @@
- `todos/` 放尚未完成的工作项,它们不是决定的记录。
- 移动或改名用 `tools/doc-tools/move_record.py`,它同时改写仓库中对该文件的引用。

共 28 篇记录(其中 0 篇已归档),1 项待办。
共 29 篇记录(其中 0 篇已归档),1 项待办。

## 进行中

- [PR #5 第二轮评审的 [nit] 修复:覆盖率按测试程序列出的用例核对](2026-11-21-pr5-review-nits-design.md) — active
- [doctest 测试接入 mtest 协议:改用上游适配器 `mcpplibs.mtest.doctest`](2026-11-21-mtest-doctest-adapter-design.md) — active
- [子工程复用根工程的构建产物,mcpp 升级到 2026.11.20.1](2026-11-20-sub-project-build-reuse-design.md) — active
- [模块测试加固的发现复盘:封装层缺陷与上游 Boost 问题(对照 1.93.0.beta1)](2026-11-12-module-tests-findings-and-upstream-bugs-analysis.md) — active

Expand All @@ -46,6 +47,7 @@
### tests

- [PR #5 第二轮评审的 [nit] 修复:覆盖率按测试程序列出的用例核对](2026-11-21-pr5-review-nits-design.md) — active
- [doctest 测试接入 mtest 协议:改用上游适配器 `mcpplibs.mtest.doctest`](2026-11-21-mtest-doctest-adapter-design.md) — active
- [子工程复用根工程的构建产物,mcpp 升级到 2026.11.20.1](2026-11-20-sub-project-build-reuse-design.md) — active
- [windows-llvm-msvc 上的进程崩溃:两个 clang 模块缺陷](2026-11-18-windows-msvc-module-crashes-analysis.md) — landed
- [示例移植脚本进入 `tools/port_tests/`:升级 Boost 时重跑上游测试的移植](2026-11-18-port-tests-tools-design.md) — landed
Expand All @@ -61,6 +63,7 @@
### 2026-11

- [PR #5 第二轮评审的 [nit] 修复:覆盖率按测试程序列出的用例核对](2026-11-21-pr5-review-nits-design.md) — active
- [doctest 测试接入 mtest 协议:改用上游适配器 `mcpplibs.mtest.doctest`](2026-11-21-mtest-doctest-adapter-design.md) — active
- [子工程复用根工程的构建产物,mcpp 升级到 2026.11.20.1](2026-11-20-sub-project-build-reuse-design.md) — active
- [windows-llvm-msvc 上的进程崩溃:两个 clang 模块缺陷](2026-11-18-windows-msvc-module-crashes-analysis.md) — landed
- [示例移植脚本进入 `tools/port_tests/`:升级 Boost 时重跑上游测试的移植](2026-11-18-port-tests-tools-design.md) — landed
Expand Down
6 changes: 5 additions & 1 deletion docs/architecture.md
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,11 @@ keeps byte-identical notices.
1.92.0 release to a case or a reason; `tools/ci/test_coverage.py check` runs
in CI, and on the linux-gcc x86_64 legs also checks each case against the
cases the built test programs list (doctest `--list-test-cases`, Boost.Test
`--list_content`). The mechanically ported files (their header says so) are generator
`--list_content`). The doctest programs speak the mtest test protocol through
the `mcpplibs.mtest.doctest` dev-dependency, which compiles doctest's
implementation and `main` once: a test file includes `<doctest/doctest.h>` and
defines no `DOCTEST_CONFIG_IMPLEMENT*`, and `mcpp test --cases` / `--case` act on
their cases. The mechanically ported files (their header says so) are generator
output: `tools/port_tests/regen.py` re-creates them from the release archive
and the oracle, after a Boost upgrade followed by `test_coverage.py scan` and
`link`. `tests/dll/` (with plugin shared libraries) and `tests/test/utf/`
Expand Down
5 changes: 4 additions & 1 deletion docs/architecture.zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,10 @@ feature(两种 Boost.Test 形态绝不能链接在一起)。
文档中的代码(`doc*.cpp`、`api*.cpp`)、各定制点上的自定义类型(`custom_types.cpp`),
以及 `coverage.toml`:1.92.0 发布包中每个示例和文档章节都映射到一个用例或写明理由;
CI 运行 `tools/ci/test_coverage.py check`,并在 linux-gcc x86_64 腿上按构建出的测试程序
列出的用例(doctest `--list-test-cases`、Boost.Test `--list_content`)核对每个用例。机械移植的文件(头注释写明)是生成结果:
列出的用例(doctest `--list-test-cases`、Boost.Test `--list_content`)核对每个用例。
doctest 程序经由 dev-dependency `mcpplibs.mtest.doctest` 实现 mtest 测试协议,doctest 的实现与
`main` 只编译一次:测试文件只包含 `<doctest/doctest.h>`,不定义 `DOCTEST_CONFIG_IMPLEMENT*`,
`mcpp test --cases` / `--case` 作用于其中的用例。机械移植的文件(头注释写明)是生成结果:
`tools/port_tests/regen.py` 从发布包和 oracle 重新生成它们(升级 Boost 后运行,
再跑 `test_coverage.py scan` / `link`)。`tests/dll/`(带插件共享库)与
`tests/test/utf/`(Boost.Test 的编译形态)是独立工程,被根清单的 `[test] discover`
Expand Down
1 change: 1 addition & 0 deletions mcpp.toml
Original file line number Diff line number Diff line change
Expand Up @@ -737,6 +737,7 @@ kind = "lib"
# The test programs under tests/<lib>/ are doctest programs, one per file.
[dev-dependencies]
compat.doctest = "2.4.12"
mcpplibs.mtest.doctest = "0.11.1"

# tests/dll/ (shared-library plugins) and tests/test/utf/ (the compiled
# Boost.Test form, which needs the unit-test-framework feature on) are projects
Expand Down
1 change: 0 additions & 1 deletion tests/algorithm/api_sequences.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// mcpplibs.mwrap.boost.algorithm — the sequence algorithms (cxx11/14/17,
// searching, hex, gather, clamp, ordering, permutation) through the module.
// Cases named "doc: <section>" carry the Examples of libs/algorithm/doc/<x>.qbk.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
import std;
import mcpplibs.mwrap.boost.algorithm;
Expand Down
1 change: 0 additions & 1 deletion tests/algorithm/api_string.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// mcpplibs.mwrap.boost.algorithm — the string algorithms (boost/algorithm/
// string.hpp, trim_all) through the module: case conversion, trimming,
// predicates, find/replace/erase families, split/join, finders and formatters.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
import std;
import mcpplibs.mwrap.boost.algorithm;
Expand Down
1 change: 0 additions & 1 deletion tests/algorithm/custom_types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
// comparators (function objects, function pointers, lambdas), user iterators
// (a bidirectional list-like container), and string algorithms over a user
// character sequence.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
import std;
import mcpplibs.mwrap.boost.algorithm;
Expand Down
1 change: 0 additions & 1 deletion tests/algorithm/examples.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
// case keeps the example's data and calls and turns what it prints into
// checks. string/example/regex_example.cpp is include_string_regex.cpp: the
// *_regex family is not in the module (tools/export_policy.toml [algorithm]).
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
import std;
import mcpplibs.mwrap.boost.algorithm;
Expand Down
1 change: 0 additions & 1 deletion tests/algorithm/include_string_regex.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
// as headers. No import in this TU (gcc include+import ODR rule). Covers
// libs/algorithm/string/example/regex_example.cpp; regex's compiled TUs come
// from the package's base source list.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <string>
#include <vector>
Expand Down
1 change: 0 additions & 1 deletion tests/any/api.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// mcpplibs.mwrap.boost.any — boost::any, boost::anys::basic_any and
// boost::anys::unique_any: construction, assignment, swap, the any_cast
// family (value, reference, pointer, rvalue), unsafe_any_cast, type queries.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
import std;
import mcpplibs.mwrap.boost.any;
Expand Down
1 change: 0 additions & 1 deletion tests/any/custom_types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
// move-only allowed for unique_any), small-object storage vs heap storage,
// a throwing copy constructor leaving the target unchanged, and destructors
// running exactly once.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
import std;
import mcpplibs.mwrap.boost.any;
Expand Down
1 change: 0 additions & 1 deletion tests/any/examples.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
// mcpplibs.mwrap.boost.any — the documentation examples of Boost.Any
// (libs/any/doc/any.qbk, sections "Examples" and "C++20 module") as test cases.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
import std;
import mcpplibs.mwrap.boost.any;
Expand Down
1 change: 0 additions & 1 deletion tests/asio/api_overview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
// (libs/asio/doc/overview/*.qbk, std_executors.qbk, using.qbk), one case per
// page: the features they describe, exercised in-process (loopback sockets,
// pipes, timers, signals) through the module. Cases are "doc: <page>#<id>".
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <csignal>
#include <boost/asio/detail/config.hpp> // BOOST_ASIO_HAS_* feature macros
Expand Down
3 changes: 1 addition & 2 deletions tests/asio/custom_types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
// IoObjectService, a user CancellationHandler, user SyncRandomAccessRead/
// WriteDevice types for read_at / write_at, and a user asynchronous
// operation built with async_initiate (asynchronous_operations.qbk).
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <csignal>
import std;
Expand Down Expand Up @@ -161,7 +160,7 @@ TEST_CASE("a user completion token") {
user::async_sum(t, 1, 1, user::log_token{&log});
ctx.run();
REQUIRE(log.size() == 1);
CHECK(log[0].find("[2]") != std::string::npos);
CHECK(log[0].contains("[2]"));
}

TEST_CASE("doc: WaitToken#WaitToken") {
Expand Down
1 change: 0 additions & 1 deletion tests/asio/examples_cpp11.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
// C library's own text for it differs between platforms); programs that need
// a POSIX stream_descriptor or socketpair are compiled only where asio has them.
// The actor benchmark passes its token 500 thousand times, not 50 million.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <cstdio>
#include <boost/asio/detail/config.hpp>
Expand Down
1 change: 0 additions & 1 deletion tests/asio/examples_cpp14.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
// C library's own text for it differs between platforms); programs that need
// a POSIX stream_descriptor or socketpair are compiled only where asio has them.
// The actor benchmark passes its token 500 thousand times, not 50 million.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <cstdio>
#include <boost/asio/detail/config.hpp>
Expand Down
1 change: 0 additions & 1 deletion tests/asio/examples_cpp20.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
// C library's own text for it differs between platforms); programs that need
// a POSIX stream_descriptor or socketpair are compiled only where asio has them.
// The actor benchmark passes its token 500 thousand times, not 50 million.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <cstdio>
#include <boost/asio/detail/config.hpp>
Expand Down
2 changes: 1 addition & 1 deletion tests/asio/network_cpp11.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
#include <sys/socket.h>
#include <sys/uio.h>
#endif
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <cstdio>
#include <cstdlib>
Expand All @@ -23,6 +22,7 @@
#include <boost/asio/detail/handler_tracking.hpp>
#include <cassert>
#include <boost/config.hpp>
#include <cmath>
import std;
import mcpplibs.mwrap.boost.asio;

Expand Down
2 changes: 1 addition & 1 deletion tests/asio/network_cpp14_cpp20.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@
// ports (13, 55555, 54321) are replaced by the free one, "daytime"/"http"
// service names by its number, and output that carries the time of day is
// not compared.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <cstdio>
#include <cstdlib>
#include <boost/asio/detail/config.hpp>
#include <boost/asio/coroutine.hpp>
#include <cassert>
#include <boost/config.hpp>
#include <csignal>
import std;
import mcpplibs.mwrap.boost.asio;

Expand Down
2 changes: 1 addition & 1 deletion tests/asio/network_http.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@
// ports (13, 55555, 54321) are replaced by the free one, "daytime"/"http"
// service names by its number, and output that carries the time of day is
// not compared.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <cstdio>
#include <boost/asio/detail/config.hpp>
#include <boost/asio/coroutine.hpp>
#include <cassert>
#include <csignal>
import std;
import mcpplibs.mwrap.boost.asio;

Expand Down
1 change: 0 additions & 1 deletion tests/asio/network_serialization.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
// ports (13, 55555, 54321) are replaced by the free one, "daytime"/"http"
// service names by its number, and output that carries the time of day is
// not compared.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
#include <cstdio>
#include <boost/asio/detail/config.hpp>
Expand Down
1 change: 0 additions & 1 deletion tests/beast/custom_types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
// websocket::stream with its own teardown / async_teardown /
// beast_close_socket overloads, and the
// compile-time traits rejecting types that do not model the concepts.
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>
import std;
import mcpplibs.mwrap.boost.beast;
Expand Down
Loading
Loading