wasinpwg / openai-test-generator
This is my package openai-test-generator
Requires
- php: ^8.1
- illuminate/contracts: ^10.0
- openai-php/laravel: ^0.5.3
- spatie/laravel-package-tools: ^1.14.0
Requires (Dev)
- laravel/pint: ^1.0
- nunomaduro/collision: ^7.9
- nunomaduro/larastan: ^2.0.1
- orchestra/testbench: ^8.0
- pestphp/pest: ^2.0
- pestphp/pest-plugin-arch: ^2.0
- pestphp/pest-plugin-laravel: ^2.0
- phpstan/extension-installer: ^1.1
- phpstan/phpstan-deprecation-rules: ^1.0
- phpstan/phpstan-phpunit: ^1.0
- spatie/laravel-ray: ^1.26
This package is auto-updated.
Last update: 2024-11-15 07:07:13 UTC
README
This Laravel package allows you to generate automated tests for your application using OpenAI, a powerful language model. With this package, you can quickly create test cases for your Laravel codebase, saving you time and effort in writing tests manually.
Installation
You can install the package via composer:
composer require wasinpwg/openai-test-generator --dev
Next publish the config file with:
php artisan vendor:publish --provider="OpenAI\Laravel\ServiceProvider" php artisan vendor:publish --tag="openai-test-generator-config"
Set environment variable OPENAI_API_KEY
in .env
file.
OPENAI_API_KEY=sk-xxxxxx
Usage
php artisan openai:generate-test --class="App\Http\Controller\UserController" --class="App\Http\Controller\PostController"
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.