faissaloux/pest-plugin-database
Pest plugin for databases structure
4
| Install | |
|---|---|
composer require faissaloux/pest-plugin-database |
|
| Latest Version: | v0.3.0 |
| PHP: | ^8.2 |
| License: | MIT |
| Last Updated: | Apr 30, 2026 |
| Links: | GitHub · Packagist |
Maintainer: faissaloux
PEST PLUGIN DATABASE
A pest plugin to test your database structure.
Requirements
- php ^8.2
- pestphp ^3.0 | ^4.0
- Laravel ^11.0 | ^12.0
Installation
composer require faissaloux/pest-plugin-database --dev
Supported Drivers
- MySQL
- SQLite
- PostgreSQL
Expectations
Check driver.
expect()->driver->toBe('mysql');
Check database name.
expect()->database->toBe('database');
Check tables in your database.
expect()->database->tables->toBe(['users', 'posts']);
Check number of tables in your database.
expect()->database->tables->toHaveCount(9);
Check for specific connection.
expect('connection')->database->toBe('database');
Support
If you encounter any issues or have questions, feel free to open an issue on this repository's Issues page. I'll try to respond as soon as possible.
Related Packages
Version History
| Version | Released | PHP | Laravel | License |
|---|---|---|---|---|
| v0.3.0 | ^8.2 | ^11.0| | MIT | |
| v0.2.0 | ^8.2 | ^11.0| | MIT | |
| v0.1.0 | ^8.2 | ^11.0| | MIT |