2017 © Pedro Peláez
 

library testphase

API testing environment build for phramework and RESTful APIs

image

phramework/testphase

API testing environment build for phramework and RESTful APIs

  • Monday, January 30, 2017
  • by nohponex
  • Repository
  • 3 Watchers
  • 3 Stars
  • 6,942 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 24 Open issues
  • 20 Versions
  • 6 % Grown

The README.md

testphase

API testing environment build for phramework and RESTful APIs, (*1)

Coverage Status Build Status StyleCI, (*2)

Usage

Require package using composer, (*3)

composer require phramework/testphase

Execute tests written in JSON files using command line

./vendon/bin/testphase help -b ./bootstrap.php -d ./tests-directory/

Inside your bootstrap.php file you MAY use the Testphase::setBase method to set the base url of your API. For example: Testphase::setBase('http://localhost/myapp/api/');, (*4)

Execute tests in PHP scripts

$test = (new Testphase(
    'posts/notFound',
    'GET',
    [
        'Accept: application/json'
    ]
))
->expectStatusCode(404)
->expectJSON()
->run();

Development

Install

composer update

Lint and test code

composer lint
composer test

Testing relies on JSONPlaceholder service., (*5)

Generate documentation

composer doc

License

Copyright 2015 - 2016 Xenofon Spafaridis, (*6)

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at, (*7)

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License., (*8)

The Versions

30/01 2017
25/05 2016

dev-dev-test-files-report

dev-dev-test-files-report https://phramework.github.io/

API testing environment build for phramework and RESTful APIs

  Sources   Download

Apache-2.0

The Requires

 

The Development Requires

22/02 2016
21/02 2016
21/02 2016
10/02 2016

dev-dev-reports

dev-dev-reports https://phramework.github.io/

API testing environment build for phramework and RESTful APIs

  Sources   Download

Apache-2.0

The Requires

 

The Development Requires

10/02 2016
25/01 2016
25/01 2016
22/01 2016
21/01 2016
20/01 2016
19/01 2016
10/01 2016
03/01 2016
22/11 2015

0.0.0

0.0.0.0 https://nohponex.gr

API response testing tool for phramework

  Sources   Download

Apache-2.0

The Requires

 

The Development Requires