nekofar / slim-test
Slim Framework test helper built on top of the PHPUnit test framework
Fund package maintenance!
ud.me/nekofar.crypto
Installs: 28 878
Dependents: 2
Suggesters: 0
Security: 0
Stars: 4
Watchers: 3
Forks: 1
Open Issues: 3
Requires
- php: >=8.1
- illuminate/testing: ^10.0
- phpunit/phpunit: ^10.0
- selective/test-traits: ^2.0 || ^3.0 || ^4.0
- slim/psr7: ^1.0
- slim/slim: ^4.0
Requires (Dev)
- ext-json: *
- ergebnis/phpstan-rules: ^1.0 || ^2.0
- nekofar/dev-tools: ^3.1
- php-di/slim-bridge: ^3.0
- phpstan/phpstan-strict-rules: ^1.0
- v3.2.5
- v3.2.4
- v3.2.3
- v3.2.2
- v3.2.1
- v3.2.0
- v3.1.1
- v3.1.0
- v3.0.1
- v3.0.0
- v2.0.7
- v2.0.6
- v2.0.5
- v2.0.4
- v2.0.3
- v2.0.2
- v2.0.1
- v2.0.0
- v2.0.0-alpha.3
- v2.0.0-alpha.2
- v2.0.0-alpha.1
- v2.0.0-alpha.0
- dev-master / 1.x-dev
- v1.1.15
- v1.1.14
- v1.1.13
- v1.1.12
- v1.1.11
- v1.1.10
- v1.1.9
- v1.1.8
- v1.1.7
- v1.1.6
- v1.1.5
- v1.1.4
- v1.1.3
- v1.1.2
- v1.1.1
- v1.1.0
- v1.0.2
- v1.0.1
- v1.0.0
- v1.0.0-beta.3
- v1.0.0-beta.2
- v1.0.0-beta.1
- v1.0.0-beta.0
- dev-develop
- dev-dependabot/github_actions/develop/softprops/action-gh-release-2.2.1
This package is auto-updated.
Last update: 2025-01-08 18:58:08 UTC
README
Slim Framework test helper built on top of the PHPUnit test framework
This library inspired by the Illuminate Testing component.
Installation
To get started, install the package using composer:
composer require nekofar/slim-test --dev
Requires Slim Framework 4 and PHP 8.0 or newer.
Usage
use Nekofar\Slim\Test\Traits\AppTestTrait; use PHPUnit\Framework\TestCase as BaseTestCase; class TestCase extends BaseTestCase { use AppTestTrait; protected function setUp(): void { $app = require __DIR__ . '/../config/bootstrap.php'; $this->setUpApp($app); } public function testHomePage(): void { $this->get('/') ->assertOk() ->assertSee('Welcome'); } }
Contributing
Please see CONTRIBUTING for details.
License
The MIT License (MIT). Please see License File for more information.