Download the PHP package uiii/pw-test without Composer

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

Tense

Packagist travis-linux travis-osx AppVeyor

Tense (Test ENvironment Setup & Execution) is a command-line tool to easily run tests agains multiple versions of ProcessWire CMF.

Are you building a module, or a template and you need to make sure it works in all supported ProcessWire versions? Then Tense is exactly what you need. Write the tests in any testing framework, tell Tense which ProcessWire versions you are interested in and it will do the rest for you.

See example or see usage in a real project.

Table of Contents

  1. Requirements
  2. Installation
  3. Usage
  4. Configuration
  5. Troubleshooting

Requirements

php.ini

php.ini used by php cli command must have enabled these extensions:

Installation

Don't forget to setup all requirements first.

Install globally:

or install as a project dependency:

Usage

Go to your project's root directory.

  1. create config file tense.yml:

  2. run tests:

if you've installed Tense locally as project's dependecy, use vendor/bin/tense instead of tense

Configuration

Tense uses YAML configuration files. There are two types of config files:

The project's config can be created either manually or interactively by running the command:

The local config is automatically initialized on each tense run when missing.

tmpDir

optional, config: project, local

Path to a directory where files needed for testing (e.g ProcessWire installation, ...) are stored.

Path is relative to the config file's parent directory.

Default is .tense

db

required, config: local

Database connection parameters.

They are used to create the database for ProcessWire installation, so the user must have the privileges to create a database.

db.name is a name of the database.

Example:

testTags

required, config: project

List of ProcessWire tags/versions used for testing.

It doesn't have to be exact version number. For each tag/version will be found latest matching existing tag (e.g. 3.0 -> 3.0.42).

Versions are tested in the specified order.

Minimal supported version is 2.5.

Version 2.8 is not currently supported.

Example:

copySources

optional, config: project

Copy source files into ProcessWire's' installation before testing.

It is a list of objects with destination and source properties.

Destination paths are relative to ProcessWire's installation root.

Source paths are relative to the config file's parent directory.

Sources can either be a single string or an array of strings. If the source is a string, file to file copy is used. If the source is an array of strings, the destination is considered to be a directory where all sources are copied into.

If source item is a directory, it will be copied recursively.

Example:

Consider tense.yml is in project's root and <project-root>/Libs is a directory. In this example these files will be copied:

beforeCmd

optional, config: project, local

Command to execute before a test suite, but after a PW instance is installed and sources are copied.

This is just a single command, if you need to run multiple commands, put them into an external script.

Remember, the command should be platform independent, so using .sh or .bat files are not recommended. Best option is to use PHP as you can see in the example, but you can use any other platform independent scripting language.

Path to the ProcessWire installation will be in PW_PATH environment variable.

Example:

testCmd

required, config: project

Command to execute a test suite.

Path to the ProcessWire installation will be in PW_PATH environment variable.

Example:

pause

optional, config: local

After each test suite against a ProcessWire instance but before a clean up test runner can pause and ask the user what to do.

This is useful e.g. to examine the installed ProcessWire instance.

Possible values are:

Troubleshooting

cURL error: SSL certificate problem: unable to get local issuer certificate

If you got this error, you haven't properly configured PHP's curl extension. You can solve this e.g. by

  1. download the https://curl.haxx.se/ca/cacert.pem file
  2. place it somewhere, e.g. in PHP's installation directory
  3. edit php.ini file and set curl.cainfo = <aboslute-path-to-cacert-file>

All versions of pw-test with dependencies

PHP Build Version
Package Version
Requires php Version >=5.6
justinrainbow/json-schema Version ^5.2
symfony/yaml Version ^3.2
symfony/console Version ^3.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 uiii/pw-test contains the following files

Loading the files please wait ....