Enhance a Single Test
(Chat with TestGPT)

Enhancing the generated tests with CodiumAI is a user-friendly and intuitive process, allowing you to fine-tune and customize your test suite using the powerful TestGPT model.

By following a series of steps, you can effectively communicate your desired changes, evaluate different versions of the test code, and track the modifications made throughout the enhancement process.

Enhance a <span class="gradient-text">Single Test <br>(Chat with TestGPT)</span>

Getting Started

Once you have generated your test suite, you have the ability to enhance the quality of your tests with the TestGPT model.
1

Test Suite

Within each test case in the test suite, you can see a chat box below the test code.
VS Code
Codium - VS Code
JetBrains - IntelliJ IDEA
Codium - JetBrains - IntelliJ IDEA

Within this interface, you can articulate the specific modifications and refinements, providing clear instructions for altering the test code. You can use natural language for this, which enables you to express your needs in a manner that matches the exact requirements, allowing for a seamless and efficient communication process.

Applying the changes

Once the desired changes have been specified, you can submit those requests by either pressing the "Enter" key on your keyboard
or clicking the "Send" button at the right corner of the text box.

At this point, CodiumAI's TestGPT model takes over, processing the instructions provided and generating an updated test code that reflects the requested modifications. By leveraging the power of the TestGPT model, you can expect to receive a test code that aligns with your intended enhancements, ensuring the generated tests accurately capture the desired behavior and functionality of the code.

1

Example 1:

Instructing the TestGPT model to replace the existing inputs (2 and 3) of a function (which takes two integers, adds them, and outputs the result) with new inputs (100 and 0).
VS Code
Codium - VS Code
JetBrains - IntelliJ IDEA
Codium - JetBrains - IntelliJ IDEA
2

Example 2:

Giving a condition (the numbers must be between -100 and 100) for the inputs to use within the test code.
VS Code
Codium - VS Code
JetBrains - IntelliJ IDEA
Codium - JetBrains - IntelliJ IDEA

By scrutinizing the updated test code, you can verify that the generated tests accurately validate the codebase, bolstering confidence in its correctness and robustness.

Comparing the previous code

1

CodiumAI provides a user-friendly

Note: Currently available only on VS Code editor.

To facilitate an effective comparison between different versions of the test code, CodiumAI provides a user-friendly navigation feature. It can be found above the test name of each test case.

VS Code
Codium - VS Code

Back button:

You can click this button and navigate to the previous test code generated by CodiumAI.

Next button:

After you make changes and regenerate the test code, this button will be enabled when there are several codes for the same test.

Count:

Between the Previous and Next buttons, you can see the total number of regenerated codes for a test code and the current test code.

2

Feature proves invaluable

This feature proves invaluable when tracking changes made throughout the enhancement process, enabling you to quickly evaluate different versions and determine the most suitable test code that aligns with your needs.
VS Code
Codium - VS Code

CodiumAI empowers developers to enhance the generated tests with precision and efficiency through this systematic approach. By leveraging the TestGPT model and the intuitive chat interface, you can effortlessly communicate your desired changes, receive updated test code that reflects those modifications, and evaluate different versions to ensure the test suite meets the expectations you require.

This collaborative process between you and the CodiumAI guarantees the generation of an accurate, reliable, and tailored test suite that effectively validates code.

CodiumAI

Check out other features

Gain insights into the range of innovative features that CodiumAI brings to your development toolkit, all designed to ensure superior code integrity and efficiency.