VUnitByHGB is a Visual Studio Code extension that makes it easy to debug and run VUnit testcases from the sidebar of VS-Code. This Extension is maintained by Jakob Jungreuthmayer at University of Applied Sciences Upper Austria - Campus Hagenberg.
- List all VUnit testcases from multiple run.py scripts
- Run VUnit testcases
- Debug VUnit testcases in GUI mode
- Go-To-Source: Jump to the run script
- Go-To-Testcase: Jump to the implementation of a testcase
- Highlight failed/passed testcases
- Highlight failed assertions
- Parallel execution of testcases
- Make sure that VUnit is installed (e.g. using
pip install vunit_hdl
) - Open a folder that contains a run.py script
- Open any VHDL or python file to activate the extension
- Open the Testing-SideViewContainer on the left menu bar
- All Testcases should be displayed. From here, you can:
- Press the run button to run a unit test in background
- Press the debug button to run a test in GUI mode
- Jump to the definition of a testcase
This Visual Studio Code extension is a fork of VUnit Test Explorer by Henrik Bohlin, was no longer maintained. In 2023, Jakob Jungreuthmayer made the following major changes during his bachelor`s degree at University of Applied Sciences Upper Austria - Campus Hagenberg:
- Ported to the official VS-Code-Testing-API
- Added support for multiple run.py scripts in the workspace
- Added problem matchers for Python and Modelsim/Questasim output
Contributing in the form of code, documentation, feedback, tutorial, ideas or bug reports is very welcome.
- 2019 - 2020: Henrik Bohlin
- since 2023: Jakob Jungreuthmayer
The following configuration properties are available:
Property | Description |
---|---|
vunit-by-hgb.scriptname |
consistent name of all VUnit-run-scripts (default: run.py ) |
vunit-by-hgb.python |
Path to python executable. |
vunit-by-hgb.shellOptions |
VUnit run.py command line options when running tests. |
vunit-by-hgb.guiOptions |
VUnit run.py command line options when running GUI (-g should not be added here). |
vunit-by-hgb.exportJsonOptions |
VUnit run.py command line options when discovering test with --export-json. |
vunit-by-hgb.showExecutionTime |
Display Execution-Time for every testcase |
vunit-by-hgb.executeMultipleGuiTestcases |
Executing multiple GUI-Testcases at once |
vunit-by-hgb.matchProblems |
Display Errors and Warnings from VUnit as Problems |
vunit-by-hgb.matchAssertionFailure |
Display Assertion-Failures from VUnit as Problems |
- HDLRegression is an alternative to VUnit. Use HDLRegressionByHGB to run HDLRegression tests from the VS-Code sidebar. (currently under development)
This extension is published under the GNU GPL license.