Download the PHP package vu/zf2-test-extensions without Composer

On this page you can find all versions of the php package vu/zf2-test-extensions. 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 zf2-test-extensions

vu/zf2-test-extensions

Introduction

vu/zf2-test-extensions enables easier testing of our Zf2 controllers and services. Most code contained within this project is specifically for use with VeteransUnited Zf2 projects, however is open for anyone to use.

Installation Using Composer

Add "vu/zf2-test-extensions" to the require section of your composer.json file and run a respective install or update. For more information on Composer, please visit their website.

Controllers

The abstract controllers in vu/zf2-test-extensions help ensure that controllers are fully and easily tested. This is done by mocking out the ServiceManager, Request, and Response objects upon test creation.

Action Controllers

The AbstractActionController is what should be used in place of the ActionController from Zf2. This controller will extend the Zf2 ActionController while adding in the benefits of being easier to test.

Restful Controllers

The AbstractRestfulController is what should be used in place of the AbstractRestfulController from Zf2. This controller will extend the Zf2 AbstractRestfulController while adding in the benefits of being easier to test.

Testing Controllers

When testing your controllers, you will want to extend the respective test controller on your test class. This way you can get full benefit out of the library. The extended class will set up the class you're testing and inject an instance of the ServiceLocator. Note that all test classes must implement the getControllerName() method.

Action Controllers

When testing a controller extending the AbstractActionController, you will want your test class to extend AbstractActionControllerTest. Example:

Restful Controllers

When testing a controller extending the AbstractRestfulController, you will want your test class to extend AbstractRestfulControllerTest. Example:

Services

Service Locator

The provided AbstractServiceLocatorAwareService helps by automatically injecting the Zf2 ServiceLocator into your class. Classes that will be loaded via the ServiceLocator should extend this class.

Testing Services

Service Locator

The AbstractServiceLocatorAwareServiceTest sets up the service being tested and injects an instance of the ServiceLocator for you. This should be used to test all classes that extend AbstractServiceLocatorAwareService. Note that all test classes using AbstractServiceLocatorAwareServiceTest must implement the getClassName() method


All versions of zf2-test-extensions with dependencies

PHP Build Version
Package Version
Requires php Version >=5.3.3
zendframework/zend-servicemanager Version >=2.2
zendframework/zend-mvc Version >=2.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 vu/zf2-test-extensions contains the following files

Loading the files please wait ....