Then set up tmux test fixtures so this project can test code that drives tmux. libtmux drives a real tmux server from code. It gives you objects for the server, its sessions, windows and panes. Documentation for every language is at https://libtmux.org/en/. Language: C++ Package: libtmux-cxx (its repository) Repository: https://github.com/libtmux/libtmux-cxx Read these before writing code: - https://libtmux.org/en/cxx/latest/llms.txt every page for C++, as a list - https://libtmux.org/en/cxx/latest/docs.json the same list with headings, as JSON - https://libtmux.org/en/cxx/latest/reference/ the C++ API reference If you cannot fetch URLs, clone the repository above and read its README and examples instead, or ask me to paste those pages in. Set up first: 1. Report the tmux version with `tmux -V`. libtmux drives a real tmux, so nothing below works without one. Stop and tell me if it is missing. 2. If this directory is not a C++ project yet, write a CMakeLists.txt declaring cmake_minimum_required and project(), targeting C++23. Skip this in a project that already exists, and match what is here. 3. Add the dependency. libtmux-cxx is not published to its registry yet, so this installs from the repository at tag v0.1.0-alpha.11. include(FetchContent) FetchContent_Declare(libtmux-cxx GIT_REPOSITORY https://github.com/libtmux/libtmux-cxx GIT_TAG v0.1.0-alpha.11) FetchContent_MakeAvailable(libtmux-cxx) Check https://github.com/libtmux/libtmux-cxx for a newer version, and prefer a stable release over this one if there now is any. 4. Write the smallest program that proves the install works: connect to a tmux server, create a session, confirm it is there, then kill it. Give that server a socket of its own rather than using the default one, so this never touches a tmux I am already running. Run it, and show me the output and the files you added. Rules for everything below: - Use the reference above rather than guessing names. The ten libtmux ports do not share spellings, and a name from another language will look plausible and not exist. - If the reference does not have something you expected, say so instead of writing a call that does not exist. - Follow the conventions already in this repository. Test fixtures What it does: - Gives each test an isolated tmux server on its own socket, so tests do not see each other's sessions and do not touch the tmux I am using right now. - Tears the server down when the test ends, including when it fails. - Provides a ready-made session or window for tests that need one. - Includes two example tests: one that creates a session and asserts on it, and one that sends input to a pane and asserts on the captured output. Constraints: - Use this port's own test helper rather than writing a new one. Find it in the API reference above; every port ships something for this. Do not invent a name for it. - Waiting for a program to produce output is a synchronisation problem, not a sleep. A fixed delay makes the suite slow and flaky at the same time. - Make sure a failing test cannot leak a server. Show how the teardown runs on the failure path. Anchor it in these pages: - https://libtmux.org/en/tmux/guides/testing-with-libtmux/ testing with libtmux - https://libtmux.org/en/tmux/concepts/transports/ transports For C++: Use `libtmux::testing::ScopedTmuxServer` from ``, whose destructor reports teardown.