evolver / diagnostics
Configurable diagnostic tests for PHP applications
Installs: 3 628
Dependents: 0
Suggesters: 0
Security: 0
Stars: 3
Watchers: 3
Forks: 0
Open Issues: 0
Requires
- php: >=5.4
- herrera-io/version: ~1.1
- symfony/console: ~2.6
- symfony/yaml: ~2.6
- zendframework/zenddiagnostics: ~1.0
Requires (Dev)
- phpunit/phpunit: ~4.5
This package is not auto-updated.
Last update: 2024-12-21 19:10:51 UTC
README
Configurable diagnostic tests for PHP applications based on ZendDiagnostics
Requirements
This application has the following requirements:
- PHP 5.4 or higher
Installation
You can install this application in two different ways
As a Phar release (recommended)
Download the latest release to yor project root
As a Composer dependency
Install Composer in your project:
$ curl -s https://getcomposer.org/installer | php
Create a composer.json
file in your project root:
{ "require": { "evolver/diagnostics": "dev-master" } }
Install this package via Composer:
$ php composer.phar install
Or add this package as a requirement to an existing project:
$ php composer.phar require evolver/diagnostics
Usage
Create a diagnostics.yml
file in your project root:
checks: - name: "PhpVersion" arguments: expectedVersion: "5.4" operator: ">="
You may specify any other diagnostic checks according to the sample above
This application ships with some additional diagnostic checks:
- PhpExtension - make sure given extension is (not) loaded in a defined version
Run diagnostic checks:
- with the Phar release:
$ php diagnostics.phar check
- with the Composer binary:
$ vendor/bin/diagnostics check
Additional diagnostic checks
This package comes with some additional diagnostic checks
PhpExtension
Make sure that a given extension is loaded
checks: - name: "PhpExtension" arguments: extensionName: "mbstring"
Make sure that a given extension is loaded in a defined version
checks: - name: "PhpExtension" arguments: extensionName: "yaml" extensionVersion: "1.1.1"
Make sure that a given extension is absent
checks: - name: "PhpExtension" arguments: extensionName: "apc" extensionVersion: false