|
testcontainers-cpp 0.2.0
Native C++20 Testcontainers over the Docker Engine API
|
| Ntestcontainers | |
| Ndocker | |
| CBuildOptions | Options for POST /build — the knobs the Docker build endpoint accepts that we surface |
| CTransportTimeouts | Deadlines the transport layer applies to Docker daemon I/O, so a wedged daemon or a network black-hole fails with an error instead of blocking the calling thread forever |
| Nmodules | |
| CClickHouseImage | A reusable, copyable description of a ClickHouse test server: image, credentials, init scripts, and server-config drop-ins |
| CClickHouseContainer | A running ClickHouse server: endpoint getters plus the owned container |
| CKafkaImage | A single-node Apache Kafka broker in KRaft mode (no ZooKeeper), for tests |
| CKafkaContainer | A running single-node Kafka broker: address getters plus the owned container |
| CMariaDBImage | A reusable, copyable description of a MariaDB server container |
| CMariaDBContainer | A running MariaDB server: connection getters plus the owned container |
| CMinIOImage | A reusable, copyable description of a MinIO object-storage server — an S3-compatible endpoint for tests: pinned image, S3 + console ports, root credentials, buckets to pre-create, and an HTTP readiness probe |
| CMinIOContainer | A running MinIO server: S3 endpoint getters plus the owned container |
| CMongoDBImage | A MongoDB server for tests: a copyable, reusable description of a mongo container that always runs as a SINGLE-NODE REPLICA SET, so sessions, multi-document transactions, and change streams work out of the box |
| CMongoDBContainer | A running MongoDB server (a single-node replica-set PRIMARY): connection getters plus the owned container |
| CMosquittoImage | A reusable, copyable description of an Eclipse Mosquitto MQTT broker: the pinned image, port 1883 exposed, and a managed mosquitto.conf (copied in before start) that accepts anonymous clients from outside the container — the stock image config would listen on the container's loopback only, so the mapped port would connect to nothing |
| CMosquittoContainer | A running Mosquitto broker: connection getters plus the owned container |
| CMySQLImage | A reusable, copyable description of a MySQL server container |
| CMySQLContainer | A running MySQL server: connection getters plus the owned container |
| CNATSImage | A reusable, copyable description of a NATS server container: the pinned image, the client and HTTP-monitoring ports, a log + /healthz readiness pair, and optional credentials / JetStream / extra server flags — all rendered into the command line (the server reads no environment) |
| CNATSContainer | A running NATS server: connection getters plus the owned container |
| COpenSearchImage | A reusable, copyable description of a single-node OpenSearch server for tests, running with the security plugin DISABLED: plain HTTP on one published port, no credentials — OpenSearchContainer::http_url() is all a REST client needs |
| COpenSearchContainer | A running OpenSearch server: URL getters plus the owned container |
| CPostgreSQLImage | A reusable, copyable description of a PostgreSQL test database: image, credentials, init scripts, and server configuration |
| CPostgreSQLContainer | A running PostgreSQL server: connection getters plus the owned container |
| CRabbitMQImage | A reusable, copyable description of a RabbitMQ broker: image, credentials, virtual host, preloaded definitions, and plugins to enable |
| CRabbitMQContainer | A running RabbitMQ broker: connection getters plus the owned container |
| CRedisImage | A reusable, copyable description of a Redis server container: the pinned image, the exposed server port, an in-container redis-cli ping readiness probe, and optional password / extra server arguments |
| CRedisContainer | A running Redis server: connection getters plus the owned container |
| CRustFSImage | A reusable, copyable description of a RustFS server — an S3-compatible object store — for tests: pinned image, S3 + console ports, managed access/secret credentials, and an HTTP readiness probe |
| CRustFSContainer | A running RustFS server: S3 endpoint getters plus the owned container |
| CScyllaDBImage | A reusable, copyable description of a single-node ScyllaDB server for tests: CQL on port 9042, developer mode, one shard, no authentication — the vendor-recommended CI shape, typically CQL-ready in seconds |
| CScyllaDBContainer | A running single-node ScyllaDB server: contact-point getters plus the owned container |
| Nwait_for | Readiness conditions: the alternative types a WaitFor can hold, plus the convenience factories (below) that build them |
| CNone | No readiness condition — start() returns as soon as the container is started |
| CLogMessage | Wait until a substring appears in the container's logs a number of times |
| CDuration | Wait for a fixed duration after start (a coarse fallback strategy) |
| CExit | Wait until the container stops, optionally with a specific exit code |
| CHealthcheck | Wait until the container's Docker health status becomes "healthy" |
| CHttp | Wait until an HTTP GET to the mapped host port returns expected_status |
| CPort | Wait until the mapped host port for port accepts a TCP connection |
| CCommand | Wait until a command run inside the container (via exec) exits with code 0 |
| CConnectionString | Assembles a connection URL — scheme://[user[:password]@]host[:port][/database][?key=value&...] — percent-encoding every component that needs it |
| CContainer | A RAII handle to a running container, normally obtained from GenericImage::start() |
| CContainerPort | A port exposed by a container, with its protocol |
| CContainerRequest | The complete "what to run" for one container: the Docker create spec plus every run-time input the start orchestration needs (readiness conditions, files to copy in, lifecycle hooks, pull/reuse/retry policy) |
| CCopyToContainer | A request to copy a host file, in-memory bytes, or a host directory tree into a container, mapping to a tar PUTed to PUT /containers/{id}/archive |
| CDevice | A host device node mapped into the container (a HostConfig.Devices entry) — docker run --device parity |
| CCreateContainerSpec | The flat create-body DTO for POST /containers/create, shared between the builder layer (ContainerRequest renders into it) and the client — typed fields for every option the library surfaces, translated into the daemon's JSON in one place |
| CNetworkIpamPool | One IPAM address pool of a network — an IPAM.Config entry, both as sent by POST /networks/create (NetworkCreateSpec::ipam_pools) and as read back by GET /networks/{id} (NetworkInspect::ipam_pools) |
| CNetworkCreateSpec | Options for POST /networks/create (richer than just name+labels) |
| CVolumeCreateSpec | Options for POST /volumes/create |
| CVolumeInspect | The subset of GET /volumes/{name} we care about |
| CVolumePruneResult | The daemon's report from POST /volumes/prune |
| CNetworkEndpoint | One attached container's endpoint on a network (a Containers map entry in GET /networks/{id}) |
| CNetworkInspect | The subset of GET /networks/{id} we currently care about |
| CImageInspect | The subset of GET /images/{reference}/json we currently care about |
| CPortBinding | A single published port binding from a container inspect |
| CContainerSummary | A subset of one entry from GET /containers/json (the list endpoint) |
| CHostConfigInspect | The HostConfig subset echoed back by GET /containers/{id}/json — the typed create-side knobs, readable back so tests can assert a limit landed |
| CContainerInspect | The subset of GET /containers/{id}/json we currently care about |
| CResponse | An HTTP response from the Docker Engine API |
| CDockerClient | A synchronous client for the Docker Engine HTTP API |
| CSession | While alive, THIS client instance keeps its daemon connection open across requests and reuses it for consecutive idempotent GET calls — all other requests keep opening fresh connections, so a stale-connection retry can never replay a side effect |
| CPullRetry | Bounded-retry policy for pull_image (see set_pull_retry) |
| CContainerPathStat | Metadata of a container path, decoded from the X-Docker-Container-Path-Stat header of a HEAD /containers/{id}/archive probe — a cheap existence/size check before a download (no archive is transferred) |
| CTlsMaterials | TLS material paths attached to a resolved endpoint — filled by DockerHost::resolve() when the active docker context stores them (~/.docker/contexts/tls/...) |
| CDockerHost | A resolved Docker daemon endpoint: where and how to reach the daemon |
| CLogOptions | Options for GET /containers/{id}/logs |
| CContainerLogs | Combined stdout / stderr text retrieved from a container |
| CDockerComposeContainer | A RAII handle to a running Docker Compose project |
| CError | Base class for all testcontainers-cpp exceptions |
| CDockerError | Failure while talking to the Docker daemon (transport, HTTP, or API error) |
| CNotFoundError | The daemon replied 404: the referenced resource does not exist |
| CTransportTimeoutError | A transport operation exceeded its deadline — the TransportTimeouts connect budget or per-operation io deadline (see docker/Timeouts.hpp), or an internal handshake budget (the Ryuk registration) |
| CStartupTimeoutError | A container/service did not become ready within the caller's startup / wait-strategy timeout |
| CExecOptions | Options for running a command inside a container via exec |
| CExecResult | The result of running a command inside a container via exec |
| CExecStreamResult | The result of a deadline-bounded streaming exec (the overload taking a deadline): why output delivery ended, plus the exit code when the command had actually finished by then |
| CGenericBuildableImage | A reusable, copyable description of an image to BUILD from a Dockerfile and a build context |
| CGenericImage | A reusable, copyable description of a container to run: image reference, exposed ports, environment, command, labels, and readiness conditions |
| CHealthcheck | A container HEALTHCHECK definition, mirroring Docker's create-body Healthcheck object |
| CMount | A single filesystem mount for a container, mapping to one entry of Docker's create-body HostConfig.Mounts array |
| CNetwork | A RAII handle to a user-defined Docker network |
| CBuilder | A copyable builder for a richer user-defined network: driver, internal / attachable / IPv6 flags, IPAM address pools, driver options, and labels |
| CRegistryAuth | Credentials for a Docker registry, used to pull private images |
| CRestartPolicy | A daemon-side restart policy (HostConfig.RestartPolicy): when the container exits, the daemon itself restarts it |
| CTtySize | A pseudo-TTY's dimensions in character cells |
| CUlimit | A process resource limit (HostConfig.Ulimits entry), e.g. {"nofile", 1024, 2048} |
| CVolume | A RAII handle to a named Docker volume |
| CBuilder | A copyable builder for a richer named volume: driver, driver options, and labels |