Download the PHP package chaplean/unit-bundle without Composer

On this page you can find all versions of the php package chaplean/unit-bundle. 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 unit-bundle

Getting Started With ChapleanUnitBundle

Prerequisites

This version of the bundle requires Symfony 2.8+.

Installation

1. Composer

2. AppKernel.php

Add

3. Import configuration

3.1. Import unit file config in config_test.yml
3.2. Configure mock (optional)

In config_test.yml

Example class:

3.3. Add parameter (optional)

Open app/config/parameters* files

Add and change the default value. The false value disable the loading of datafixtures.

Role Provider

You can use phpunit's to automaticaly run a test with a list of different values. We can use this to test a route against different roles with a single unit test. To acheive this we will need to

  1. list the roles and how to log as a user of that role
  2. create a dataProvider giving for each role the expectations we want (usually a http code)
  3. write the test using the @dataProvider

1. Listing the roles

Add in your a dict as following:

2. Create a dataProvider

Add a provider in your test class:

3. Create a unittest

Write unittests using the previous dataProvider

Custom printer

If you want use a custom printer add printerClass attribute with Chaplean\Bundle\UnitBundle\TextUI\ResultPrinter value in phpunit.xml

See an overview


All versions of unit-bundle with dependencies

PHP Build Version
Package Version
Requires php Version >=7.1
doctrine/doctrine-bundle Version ^1.6
doctrine/doctrine-fixtures-bundle Version ^3.0
doctrine/orm Version ^2.5
liip/functional-test-bundle Version ^1.9
mockery/mockery Version ^1.0
nelmio/alice Version ^2.0
phpunit/phpunit Version ^7.0
symfony/config Version ^3.0 || ^4.0
symfony/dependency-injection Version ^3.0|^4.0
symfony/yaml Version ^3.0 || ^4.0
symfony/browser-kit Version ^3.0 || ^4.0
symfony/dom-crawler Version ^3.0 || ^4.0
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 chaplean/unit-bundle contains the following files

Loading the files please wait ....