Skip to main content

Generate your First Test Template

To generate your first test open the file you want to analyze and choose between the following options to trigger the test template generation:

  1. Code lens: Click "create test" above any function to generate test templates for that function:

    Use code lens."

  2. Context menu: Right click into a function and select "Symflower: Generate Test Template for Function" from the context menu.

    Trigger the context menu."

  3. Keyboard shortcut: Define a keyboard shortcut to trigger Symflower's test template generation. Position your cursor within a function and hit your specified keybinding.

    Define a keyboard shortcut."

  4. Command palette: Position your cursor into a function. Open the command palette of your editor and start typing "Symflower". Select the entry "Symflower: Generate Test Template for Function".

    Use the command palette."

Symflower then generates a new test method either by extending an already existing test file or by creating a new one. The chosen file location is determined using the test path that is defined in your build configuration. If none can be found the test file is simply put within the same directory as your production code.

info

Symflower currently supports the build systems Maven and Gradle for automatic test path detection.

Give Us Feedback

Send us your feedback about Symflower! If you are missing a feature or found a problem that you think should be fixed, we encourage you to open an issue on our community issue tracker or message us at hello@symflower.com.