Automatically generate high-quality unit and integration tests for Moleculer.js microservices using AI. Smart test planning, deep mocking, and auto-validation included.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Qunit generates unit and integration tests for Moleculer.js microservices using Google's Gemini AI. It proposes a test plan for each function, writes Mocha/Sinon/Chai tests into the matching spec file, runs them, and repairs the ones that fail.
Everything runs on your machine with your own Gemini API key. There is no account, no login, and no backend server.
Features
Function detection — finds service actions, methods, and standalone functions in your TypeScript files and shows a "Generate Test" CodeLens above each one.
Test planning — Gemini proposes scenarios grouped as Critical, Logical, Error, and Edge. You choose which ones to generate.
Deep mocking — stubs broker.call() for inter-service calls and database queries, so tests run without external services.
Merging into existing tests — new tests are added to the existing spec file without overwriting what is already there.
Auto-validation and repair — generated tests run immediately; failures are analyzed and a fix is generated automatically.
Sidebar — a Qunit view in the activity bar lists detected functions, statistics, and generation history.
Requirements
VS Code 1.85 or later
A Moleculer.js project written in TypeScript, with Mocha, Sinon, and Chai installed