Skip to main content

AI-powered test case generator for Python, Java, and JavaScript with OpenAI, Anthropic, and Google Gemini support

Project description

Voylla- Test Case Generator Bot

An AI-powered agent that analyzes code and generates comprehensive test cases for Python, Java, and JavaScript.

• User Guide: https://github.com/AryanSaxenaa/Voylla/blob/main/docs/USER_GUIDE.md • API Reference: https://github.com/AryanSaxenaa/Voylla/blob/main/docs/API_REFERENCE.md • Examples: https://github.com/AryanSaxenaa/Voylla/blob/main/examples/README.md

Voylla is a Published Package https://pypi.org/project/voylla/0.1.0/

Features

  • Multi-language Support: Python, Java, JavaScript
  • Comprehensive Test Generation: Unit, integration, and edge cases
  • Code Analysis: Detects edge conditions and performance risks
  • Coverage Reports: Analyzes test coverage gaps
  • Interactive Refinement: Conversational test case improvement
  • CI Integration: GitHub Actions support for PR test suggestions

Project Structure

test-generator-bot/
├── src/
│   ├── analyzers/          # Code analysis modules
│   ├── generators/         # Test case generators
│   ├── agents/            # AI agent logic
│   └── integrations/      # CI/CD integrations
├── tests/                 # Project tests
├── examples/              # Example code and generated tests
└── config/               # Configuration files

Quick Start

  1. Install from PyPI (recommended):
    pip install voylla
    
    Or for local dev: pip install -r requirements.txt
  2. Set up AI API key (optional but recommended):
    python setup_ai.py
    
    Or manually set environment variables:
    export OPENAI_API_KEY="your-api-key-here"
    # OR
    export ANTHROPIC_API_KEY="your-api-key-here"
    # OR
    export GEMINI_API_KEY="your-api-key-here"
    
  3. Run:
    voylla --file your_code.py
    

Examples:

  • Python: voylla -f examples/sample_code.py -l python -o test_output
  • JavaScript (auto): voylla -f examples/sample_code.js -o test_output
  • Java (auto): voylla -f examples/Sample.java -o test_output

AI Enhancement

The bot supports multiple AI providers for enhanced test generation:

  • OpenAI GPT-4: Set OPENAI_API_KEY environment variable
  • Anthropic Claude: Set ANTHROPIC_API_KEY environment variable
  • Google Gemini: Set GEMINI_API_KEY environment variable
  • Auto-detection: Will use available provider automatically
  • Mock Mode: Works without API keys (basic enhancement only)

Environment Variables

Copy .env.example to .env and configure:

# Choose provider: "openai", "anthropic", "gemini", "auto", or "mock"
AI_PROVIDER=auto
OPENAI_API_KEY=your_openai_api_key_here
ANTHROPIC_API_KEY=your_anthropic_api_key_here
GEMINI_API_KEY=your_gemini_api_key_here

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

voylla-0.2.0.tar.gz (84.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

voylla-0.2.0-py3-none-any.whl (98.3 kB view details)

Uploaded Python 3

File details

Details for the file voylla-0.2.0.tar.gz.

File metadata

  • Download URL: voylla-0.2.0.tar.gz
  • Upload date:
  • Size: 84.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for voylla-0.2.0.tar.gz
Algorithm Hash digest
SHA256 c5ff96780fe98fa851f595c47b3c74c4d691c8a1ba405953a7fbc1c491a175da
MD5 091c0f5b739358f0ca872f6b65b5d179
BLAKE2b-256 b11a90fd91da7122406cf0a5097f45b694b700bb64c7a68c25877752100563c6

See more details on using hashes here.

File details

Details for the file voylla-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: voylla-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 98.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for voylla-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 917da8c8d10c58a6bcd917a28a3c9ade96de86073577d0f6a3a2c85a2931b3c6
MD5 3d2d33664b41b62880f26e0b7e955f20
BLAKE2b-256 e28adcc670719097514a4bab43a213552d5390c0b96733f99d0b40add9edad49

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page