How it worksFeaturesDocsEarly accessGitHubDashboard

How to create Unit Test Generator using MCP

Generate comprehensive unit tests for any function. This guide creates the Unit Test Generator prompt from Arthur's template catalog, sets up a blank MCP server, and links the prompt so any connected AI client can use it.

Steps

  1. Go to Prompt Templates and search for Unit Test Generator.

    Open the Prompt Templates catalog

    Search the catalog for the Unit Test Generator template

  2. Click Use template on the Unit Test Generator card and review the prefilled name, description, and content preview.

    Open the Unit Test Generator template with its prefilled name and content preview

    Create the Unit Test Generator prompt in the shared library

  3. Click Create prompt — the prompt is added to your shared library.

    Start creating the MCP server that will expose the prompt

  4. Go to New server, choose Blank / Static as the source, and click Next.

    Choose the Blank / Static source — no external connection is needed for a prompt-only server

    Advance to the server details step

    Name the server after the prompt it will expose

    Create the blank MCP server

    Open the server's Prompts tab

  5. Name the server (for example, Unit Test Generator Server) and click Create server.

    Open the prompt-library picker

  6. On the server's Prompts tab, click Add prompt, search for Unit Test Generator, and click Add.

    Search the library for the Unit Test Generator prompt

    Link the Unit Test Generator prompt to the server

    Close the picker and show the linked prompt on the Prompts tab

  7. Open the server's Connect section and click Share the MCP swagger documentation — Arthur generates the public documentation link and QR code for this server.

    Open the server's Connect section, where the MCP endpoint and its documentation live

    Open the MCP swagger documentation share panel

    Show the generated swagger documentation link and QR code for this server

Confirm it worked

The Unit Test Generator prompt appears on the server's Prompts tab, and the Connect section offers the server's MCP swagger documentation — a shareable page with setup instructions for any AI client. A connected client can now fetch the prompt through this server.

Good to know

  • Creates thorough unit tests covering happy paths, edge cases, and error conditions.
  • Arguments detected from the template: {{framework}}, {{language}}, {{code}} — callers fill these in when invoking the prompt.
  • Editing the prompt in the shared library updates it on every server where it's linked.

Related

Tutorial video