Skip to content

feat: Add AI-Powered Automated Unit Test Suite Generator#1142

Open
Rafiaminhaj wants to merge 2 commits into
imDarshanGK:mainfrom
Rafiaminhaj:feature/unit-test-generator-1091
Open

feat: Add AI-Powered Automated Unit Test Suite Generator#1142
Rafiaminhaj wants to merge 2 commits into
imDarshanGK:mainfrom
Rafiaminhaj:feature/unit-test-generator-1091

Conversation

@Rafiaminhaj

Copy link
Copy Markdown

Describe the changes

This PR implements the AI-Powered Automated Unit Test Suite Generator feature under GSSoC '26 (resolving #1091).

Backend Implementation

  • Schemas: Added TestGenerationRequest, TestSummary, and TestGenerationResponse classes in backend/app/schemas.py.
  • Services: Added generate_tests method in LLMAnalysisClient (backend/app/services/llm_analysis.py) to interface with LLM backend providers.
  • Router: Created the API router in backend/app/routers/test_generator.py for language-specific framework auto-detection.
  • App Main: Registered the router, enabled rate-limiting in Starlette middleware, and fixed Unicode start-log encoding crashes on Windows consoles.
  • Tests: Added API endpoint tests in backend/tests/test_endpoints.py.

Frontend Implementation

  • Controls Pane: Added "Test Gen" mode button and target test framework dropdown + mock calls checkbox in frontend/index.html.
  • Results Tab/Pane: Added Test Gen results tab and content pane containing loading shimmers, summary cards, and clean test code viewers.
  • UX Polish: Integrated framework auto-selection on programming language change, copy code with visual feedback micro-animations, and file exporter/download with matching extensions.
  • Localization: Added translations for English, Tamil, Hindi, and French.

Related Issue

Closes #1091

Checklist

  • My PR title follows the format: feat/fix/docs/test: short description
  • I have added tests for new features
  • Verify all 433 unit tests pass successfully

@Rafiaminhaj Rafiaminhaj requested a review from imDarshanGK as a code owner June 28, 2026 08:21

@imDarshanGK imDarshanGK left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@github-actions

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown

👋 This PR has had no activity for 7 days.

Please push updates or comment if you still need more time.

Inactive PRs may be closed automatically after 7 more days.

@github-actions github-actions Bot added the stale label Jul 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[GSSoC '26] Proposal: Add AI-Powered Automated Unit Test Suite Generator

2 participants