https://github.com/cspray/database-testing-pdo
https://github.com/cspray/database-testing-pdo
Last synced: 5 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/cspray/database-testing-pdo
- Owner: cspray
- Created: 2025-05-06T12:24:04.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-11-25T17:42:26.000Z (7 months ago)
- Last Synced: 2025-12-20T12:39:57.228Z (6 months ago)
- Language: PHP
- Size: 11.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# cspray/database-testing-pdo
A connection adapter for [`cspray/database-testing`](https://github.com/cspray/database-testing) that allows you to
use a PDO connection for testing database interactions.
## Installation
Composer is the only supported means to install this package.
```shell
composer require --dev cspray/database-testing-pdo
```
## Quick Start
This library works by providing an implementation of the `Cspray\DatabaseTesting\ConnectionAdapter\ConnectionAdapter` interface, along with a variety of `Cspray\DatabaseTesting\ConnectionAdapter\ConnectionAdapterFactory` implementations designed to work with common databases. Check out the example appropriate for your database below or check out the "Database Connection Adapter Reference"!
All examples below will use code from the `cspray/database-testing-phpunit` extension. If you're using a different testing framework you may need to adjust your code as appropriate.
### Postgres
```php