-
Notifications
You must be signed in to change notification settings - Fork 43
Generate tests with default configuration
Olga Naumenko edited this page Apr 28, 2023
·
4 revisions
With UnitTestBot, you can generate tests
- for a package,
- for a single class or a set of classes,
- for a method or a set of methods.
- Open your Java project in IntelliJ IDEA.
- Choose the required package, class or set of classes in the Project tool window.
Right-click and choose Generate Tests with UnitTestBot or press Alt+Shift+U.
- Alternatively, in the Editor, place the caret at the required class or method.
Press Alt+Shift+U or right-click and choose Generate > Tests with UnitTestBot.
- In the Generate Tests with UnitTestBot window, tick the classes or methods you'd like to cover with tests and
press Generate Tests or Generate and Run.
Now you can see the resulting test class or classes in the Editor.
Note: if you re-generate the test for a given class or method, it will erase the previously generated test for this unit. To prevent this, rename or move the tests you want to keep. For more information, see Test sources root.
- Check system requirements
- Install or update plugin
- Generate tests with default configuration
- Fine-tune test generation
- Get use of test results
(redirect to /docs in main repo)
- Contributing guide
- Developer guide
- Naming and labeling conventions
- Interprocess debugging
- Interprocess logging
- UnitTestBot overall architecture
- Android Studio support
- Assumption mechanism
- Choosing language-specific IDE
- Code generation and rendering
- Fuzzing Platform (FP) Design
- Instrumented process API: handling errors and results
- UnitTestBot JavaScript plugin setup
- Night statistics monitoring
- RD for UnitTestBot
- Sandboxing
- UnitTestBot settings
- Speculative field non-nullability assumptions
- Symbolic analysis of static initializers
- Summarization module
- Taint analysis
- UnitTestBot decomposition
- UtUtils class
- UnitTestBot Family changes