https://github.com/k-kinzal/testcontainers-php
Test container implementation for legacy PHP
https://github.com/k-kinzal/testcontainers-php
php testcontainers
Last synced: 6 months ago
JSON representation
Test container implementation for legacy PHP
- Host: GitHub
- URL: https://github.com/k-kinzal/testcontainers-php
- Owner: k-kinzal
- License: mit
- Created: 2024-11-02T07:36:33.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2026-01-10T04:17:11.000Z (6 months ago)
- Last Synced: 2026-01-11T01:19:57.936Z (6 months ago)
- Topics: php, testcontainers
- Language: PHP
- Homepage:
- Size: 539 KB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# testcontainers-php
[](https://github.com/k-kinzal/testcontainers-php/actions)
[](https://circleci.com/gh/k-kinzal/testcontainers-php)
[](https://opensource.org/licenses/MIT)
A PHP implementation of [Testcontainers](https://testcontainers.com/) that supports PHP versions from 5.6 to 8.5, including EOL versions. This library enables you to use Docker containers for your integration tests with minimal dependencies.
If you are using a supported PHP version, consider using the official [testcontainers/testcontainers](https://packagist.org/packages/testcontainers/testcontainers) instead.
## Features
- Supports PHP 5.6 to 8.5 (including EOL versions)
- Minimal dependencies for easy integration
- Complete container lifecycle management
- Various configuration options for containers
- Multiple wait strategies to ensure services are ready
- Support for remote Docker hosts and SSH port forwarding
## Requirements
- Docker command line tool (docker CLI)
- PHP 5.6 or later
## Installation
```bash
composer require --dev k-kinzal/testcontainers-php
```
## Quick Start
```php