Download the PHP package rmiller/behat-spec without Composer

On this page you can find all versions of the php package rmiller/behat-spec. 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 behat-spec

BehatSpec

Scrutinizer Code Quality Build Status

What

Integration between Behat and PhpSpec.

Why

This is useful when rather than using the Behat context to run an application through its UI, it is instead used to implement the domain model. For more information on this way of using Gherkin features to drive domain modelling read Everzet's post on Modelling by Example

When running a feature with a Context that contains a new class that does not exist or a method you will get a fatal error. If using PhpSpec the next step would be to start specifying that class using the describe command. This set of extensions provides integration between Behat and PhpSpec so that instead of a fatal error you can choose to run the describe command for the missing class automatically.

It also uses my ExemplifyExtension so that you can automatically add examples for missing methods in a similar way.

After describing a class or method in this way the phpspec run command can be used to automatically create the class or model. Since this is the typical next step in most cases, this extension automates that by asking you if you would like to do that next.

An Example

So to use an example from the blog post linked above:

Running the feature relating to this context would result in a fatal exception normally. Instead you get a simple error and the offer to create a spec for the missing class:

The spec is created followed by an offer to run phpspec run:

Which asks to create the class:

Running Behat again will result in a similar process for the namedAndPriced method. Where an example for the method will be added to the spec and the method added to the class.

How

Installation

This package provides an extension for PhpSpec and an extension for Behat. Both need to be enabled for the full functionality.

Requires:

Require the extension:

In order to use BehatSpec with PHPSpec 2.0 series, use 0.3.* version series:

To get the phpspec run command running, you need to use latest phpspec >2.1. Otherwise that functionality will silently fail.

Configuration

Activate the Behat extension by specifying its class in your behat.yml:

Activate the PhpSpec extension by specifying its class in your phpspec.yml:

Additional configuration can be provided for the running of the phpspec run command:

It defaults to bin/phpspec for the path of phpspec and to run after the describe command. These can be overridden as follows:

Some Details

This package pulls together some other PhpSpec and Behat extensions which can also be used standalone:

PhpSpec

Behat


All versions of behat-spec with dependencies

PHP Build Version
Package Version
Requires php Version >=5.4
phpspec/phpspec Version ~2.0
rmiller/error-extension Version <0.4
rmiller/phpspec-extension Version <0.4
rmiller/exemplify-extension Version <0.4
rmiller/phpspec-run-extension Version <0.4
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 rmiller/behat-spec contains the following files

Loading the files please wait ....