Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>UnitifyNew to Visual Studio Code? Get it now.
Unitify

Unitify

HBLAB

|
86 installs
| (3) | Free
Unit test for your file
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Before we dive into the flow, let's discuss what a function unit test file is. A function unit test file is a file that contains test cases for functions within the user's content file. The content of the file can be functional requirements (spec), diagrams, or code (function logic).

Installation and execution steps: Step 1: Add API key for ChatGPT

  1. Open Visual Studio Code (VS Code).
  2. Press "Ctrl+Shift+P" (Windows) or "Cmd+Shift+P" (Mac) to open the Command Palette.
  3. Type "askGpt: Add API key for ChatGPT" and select the command from the displayed list.
  4. Enter the API key for ChatGPT when prompted.

Step 2: Open the file to create a function unit test

  1. Open the file you want to create a function unit test for.
  2. Ensure that the file has the functions that need to be tested.
  3. Select the content you want to make and highlight it.

Step 3: Run the "askGpt: Create function unit test for this file" command

  1. Press "Ctrl+Shift+P" (Windows) or "Cmd+Shift+P" (Mac) to open the Command Palette.
  2. Type "askGpt: Create function unit test for this file" and select the command from the displayed list.
  3. Type the file type you want to execute.
  4. Wait for the command to execute and queue the processing.

Congratulations! You have successfully created an automatic function unit test for your content file with the help of ChatGPT.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft