Download the PHP package mediact/testing-suite without Composer

On this page you can find all versions of the php package mediact/testing-suite. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package testing-suite

Scrutinizer Code Quality

[ABANDONED] MediaCT Testing Suite

This package has been abandoned and will not get any support. We replaced it with the youwe testing suite.

This package serves as an umbrella package for several of MediaCT's testing packages.

Installation

Usage

The testing suite can be run through the GrumPHP command.

The testing suite is also automatically run at each git commit using a git commit hook.

Components

The following components are part of the testing suite.

Coding style validation (PHPCS)

The coding style is validated using PHPCS and uses the MediaCT Coding Standard.

During the installation of the testing suite a file called phpcs.xml is added to the root of the repository which refers to the coding standard. To make adjustments to the coding standard this file can be edited and committed.

Depending on the composer type of the project an other standard will be used:

Overriding the type

The type for a project can be overridden in the composer.json config node by adding testing-suite-type to the configuration. This will allow the use of standards for a different type. The allowed values for this node are:

The configurations looks like the following:

This can be helpful when development is done in the app/code folder and force the testing suite to automatically select the correct standards.

Coding complexity validation (PHPMD)

The complexity of the code is validated using PHPMD. A file called phpmd.xml is added during the installation of the testing suite.

Static code analysis (PHPStan)

Static code analysis is executed using PHPStan. A file called phpstan.neon is added during the installation of the testing suite.

Unit tests (PHPUnit)

Unit tests are executed using PHPUnit. A file called phpunit.xml is added during the installation of the testing suite.

The unit tests are expected to be in a directory called tests. The code is expected to be in a directory called src.

Bitbucket Pipelines

When the project is hosted on Bitbucket a Pipelines script will be installed. The scripts supports a callback that will be called before composer install is executed. This callback can be used to add credentials to composer. To enable the callback go to Bitbucket Settings > Pipelines > Environment Variables and add an environment variable called COMPOSER_PRE_INSTALL_CALLBACK.

Example to add basic authentication for repo.example.com:

ESLint

Javascript linting for Magento 1 and Magento 2 projects is executed using ESLint. Two files called .eslintrc.json and .eslintignore are added to the root of the repository which contains the coding standards and files excluded from analysis.

A third file called package.json is added which contains the needed npm modules. Run npm install after the installation in order to enable ESLint:

Integration with PHPStorm

When the testing suite is installed in a PHPStorm environment it automatically configures PHPStorm to use the correct coding style.

To enable PHPCS and PHPMD inspections in PHPStorm the correct binaries need to be configured. This is a global setting in PHPStorm and can therefore not be configured by the testing suite.

The recommended way to get the correct binaries is by installing the MediaCT Coding Standard globally.

The package will be installed in the home directory of composer. The location of this directory can be found using the following command:

Open PHPStorm and go to Settings > Languages & Frameworks > PHP > Code Sniffer.

Choose "Local" for the development environment and fill in the full path to <composer_home_directory>/vendor/bin/phpcs.

Then go to Settings > Languages & Frameworks > PHP > Mess Detector.

Choose "Local" for the development environment and fill in the full path to <composer_home_directory>/vendor/bin/phpmd.

After these adjustments the coding style and complexity will be validated while typing in PHPStorm.

To enable ESLint open PHPStorm and go to Settings > Languages & Frameworks > Javascript > Code Quality Tools > ESLint.

Enable ESLint by checking Enabled. Then set the Node interpreter to Project and Configuration file to Automatic Search.


All versions of testing-suite with dependencies

PHP Build Version
Package Version
Requires php Version ^7.1
composer-plugin-api Version ^1.1 || ^2.0
enlightn/security-checker Version ^1.5
kint-php/kint Version @stable
mediact/coding-standard Version @stable
mediact/coding-standard-phpstorm Version @stable
mediact/composer-dependency-installer Version ^1.0
mediact/composer-file-installer Version ^1.0
mediact/composer-unclog-plugin Version ^1.0
phpro/grumphp Version >=0.19 <1.0
phpstan/phpstan Version @stable
phpunit/phpunit Version @stable
php-parallel-lint/php-parallel-lint Version ^1.2
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package mediact/testing-suite contains the following files

Loading the files please wait ....