pdk_test/lib.rs
1// Copyright (c) 2026, Salesforce, Inc.,
2// All rights reserved.
3// For full license text, see the LICENSE.txt file
4
5//! PDK Integration Testing Framework
6//!
7//! Framework for writing non-blocking integration tests based on Docker containers.
8//! It provides utilities for managing test environments, services and containers
9//! in a controlled and isolated way.
10//!
11//! This library provides testing functionality with support for:
12//!
13//! - Docker container management and orchestration
14//! - Predefined test services (Flex Gateway, HTTP mocks, gRPC services)
15//! - Network port management and visibility control
16//! - Test composite builders for complex scenarios
17//! - Error handling for test failures and configuration issues
18//!
19//! ## Primary types
20//!
21//! - [`TestComposite`]: main test environment orchestrator
22//! - [`TestCompositeBuilder`]: builder for configuring test environments
23//! - [`TestError`]: error type for test failures and configuration issues
24//! - [`services::flex::FlexConfig`]: Flex Gateway service configuration
25//! - [`services::flex::ApiConfig`]: API configuration for Flex Gateway
26//! - [`services::flex::PolicyConfig`]: policy configuration for Flex Gateway
27//! - [`services::httpmock::HttpMockConfig`]: HTTPMock service configuration
28//! - [`services::httpbin::HttpBinConfig`]: HTTPBin testing service configuration
29//! - [`services::grpcbin::GrpcBinConfig`]: GrpcBin gRPC testing service configuration
30//! - [`services::gripmock::GripMockConfig`]: GripMock gRPC mock service configuration
31//!
32
33pub mod error;
34mod image;
35pub mod port;
36pub mod services;
37
38mod config;
39mod probe;
40mod service;
41
42pub(crate) mod cleanup;
43mod composite;
44pub(crate) mod constants;
45mod container;
46mod handle;
47mod host;
48mod host_container;
49mod network;
50mod portpicker;
51mod runner;
52
53pub use composite::{TestComposite, TestCompositeBuilder};
54pub use error::TestError;
55pub use pdk_test_macros::pdk_test;
56
57// This module is for crate exclusive use
58#[doc(hidden)]
59pub mod __runner {
60 pub use super::runner::*;
61}