Download the PHP package kent013/artisan-command-spectator-test without Composer

On this page you can find all versions of the php package kent013/artisan-command-spectator-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 artisan-command-spectator-test

artisan-command-spectator-test

Artisan make command to generate HTTP testcases with OpenAPI and spectator.

Disclaimer

This command generate only a scaffold. You need further implementation to test your API.

I'm using api blueprint for API specification. Generating OpenAPI json with using apib2swagger.

While I'm not writing OpenAPI directly, some data such as operation ID is not natural. Perhaps it will cause a problem on this command.

Installation

Generate config file

Configuration

Default namespace

If you want to change test namespaces, please add following line in your .env file and change the values.

OpenAPI file path

You can set default open api path with adding following line in your .env file and change the values.

This value is able to overide with openapi-path option.

Command line arguments

Where APIMethodPath goes like

Will be generate all HTTP methods corresponds on the path. If you want to select HTTP methods to generate test, prefix the path with comma-separated http methods as following.

Also you can pass multiple APIMethodPath to command as following.

For example,

Using tag

If you using tag to group API paths, then you can use --tags argument as following.

Command line options

--openapi-path

Path to Open API specification. You can specify Json or Yaml path or URL.

--force

Overrite class file or not;

--tags

Generate test methods matched with tags. With no --tags option, arguments will be processed as a path. You cannot select HTTP methods with tags.

--test-name-with-path Generate test method name from path like testApiV1OrganizationProjectsPut204. By default command will use operationId like testProjects200

Example Test


All versions of artisan-command-spectator-test with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
laravel/framework Version ^10.0 || ^11.0
hotmeteor/spectator Version ^2.0
devizzent/cebe-php-openapi Version ^1.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 kent013/artisan-command-spectator-test contains the following files

Loading the files please wait ....