Open source unit testing framework release

L

Lars Asplund

Guest
Hi,

VUnit, an unit testing framework for VHDL, is now freely available on github (https://github.com/LarsAsplund/vunit). It is released under the business-friendly Mozilla Public License, v. 2.0 and features the functionality needed to realize continuous and automated testing of your VHDL code. VUnit doesn't replace but rather complements traditional testing methodologies by supporting a "test early and often" approach through automation.

A quick 6 minute introduction to unit testing can be found at https://www.youtube.com/watch?v=PZuBqcxS8t4 and a short (12 min) introduction to VUnit can be found at https://www.youtube.com/watch?v=D8s_VLD91tw.

Some of the VUnit highlights are
- Python test runner that enables powerful test administration, can handle VHDL fatal run-time errors (e.g. division by zero), and ensures test case independence.
- Scanners for identifying files, tests, file dependencies, and file changes enable for automatic (re)compilation and execution of test suites.
- Scripting as well as command line support.
- Support for running same test suite with different generics.
- VHDL test runner which enables test execution for not fully supported simulators. We currently have full support for ModelSim but Aldec support is coming soon.
- Assertion checker library that extends VHDL built-in support (assert).
- Logging framework supporting display and file output, different log levels, filtering on level and design hierarchy, output formatting and multiple loggers. Spreadsheet tool integration.
- Location preprocessor that traces log and check calls back to file and line number.
- JUnit report files for better Jenkins integration.

We are an active and responsive community but want to grow to benefit further development. You can participate by adding questions on Github, suggesting enhancement, reporting bugs, and contributing code. If you like what you see click "star" and if you want to get notified of the progress you should click "follow".

Regards,

Lars Asplund
 
On Tue, 17 Feb 2015 09:50:28 -0800, Lars Asplund wrote:

Hi,

VUnit, an unit testing framework for VHDL, is now freely available on
github (https://github.com/LarsAsplund/vunit). It is released under the
business-friendly Mozilla Public License, v. 2.0 and features the
functionality needed to realize continuous and automated testing of your
VHDL code. VUnit doesn't replace but rather complements traditional
testing methodologies by supporting a "test early and often" approach
through automation.

Interesting - another user of OSVVM too...

You may be interested to know that as of ghdl-0.32 (not yet released but
buildable from source for most systems : Mac OSX is giving a little
trouble), ghdl understands enough VHDL-2008 to support OSVVM. Should be
easy to integrate into Vunit...

https://sourceforge.net/projects/ghdl-updates/?source=navbar

-- Brian
 
Den onsdag 18 februari 2015 kl. 14:29:02 UTC+1 skrev Brian Drummond:
On Tue, 17 Feb 2015 09:50:28 -0800, Lars Asplund wrote:

Hi,

VUnit, an unit testing framework for VHDL, is now freely available on
github (https://github.com/LarsAsplund/vunit). It is released under the
business-friendly Mozilla Public License, v. 2.0 and features the
functionality needed to realize continuous and automated testing of your
VHDL code. VUnit doesn't replace but rather complements traditional
testing methodologies by supporting a "test early and often" approach
through automation.

Interesting - another user of OSVVM too...

You may be interested to know that as of ghdl-0.32 (not yet released but
buildable from source for most systems : Mac OSX is giving a little
trouble), ghdl understands enough VHDL-2008 to support OSVVM. Should be
easy to integrate into Vunit...

https://sourceforge.net/projects/ghdl-updates/?source=navbar

-- Brian

Hi Brian,

We redistribute OSVVM because it's commonly used and it's convenient for Git users to only do git pull to have the latest version instead of relying on the version provided with your simulator or manually download and unzip from osvvm.org.

VUnit doesn't require OSVVM to work and it also supports, in addition to VHDL 2008, the older VHDL 93 and 2002. Our acceptance tests run all these versions of VHDL.

We haven't tried VUnit under GHDL (maybe someone else did?) but there is a question on github (https://github.com/LarsAsplund/vunit/issues/10) regarding what simulator support people would like to see. As I said in my first post I'd like an active community so that we can put our development efforts where they are best needed. You should place your vote!

Regards,

Lars
 
Den onsdag 18 februari 2015 kl. 14:29:02 UTC+1 skrev Brian Drummond:
On Tue, 17 Feb 2015 09:50:28 -0800, Lars Asplund wrote:

Hi,

VUnit, an unit testing framework for VHDL, is now freely available on
github (https://github.com/LarsAsplund/vunit). It is released under the
business-friendly Mozilla Public License, v. 2.0 and features the
functionality needed to realize continuous and automated testing of your
VHDL code. VUnit doesn't replace but rather complements traditional
testing methodologies by supporting a "test early and often" approach
through automation.

Interesting - another user of OSVVM too...

You may be interested to know that as of ghdl-0.32 (not yet released but
buildable from source for most systems : Mac OSX is giving a little
trouble), ghdl understands enough VHDL-2008 to support OSVVM. Should be
easy to integrate into Vunit...

https://sourceforge.net/projects/ghdl-updates/?source=navbar

-- Brian

An addition to my previous post. VUnit is designed to integrate nicely with Jenkins (https://www.youtube.com/watch?v=D8s_VLD91tw) which enables you to distribute your simulations on several machines. This is never an option for many due to license costs so a free option would certainly make a difference in that area. However, the majority of our audience sits with Modelsim or Aldec so we've focused our initial efforts there. After that I would like to look into the free alternatives unless someone is willing to make that effort in parallel ;-)

/Lars
 
Den onsdag 18 februari 2015 kl. 14:29:02 UTC+1 skrev Brian Drummond:
On Tue, 17 Feb 2015 09:50:28 -0800, Lars Asplund wrote:

Hi,

VUnit, an unit testing framework for VHDL, is now freely available on
github (https://github.com/LarsAsplund/vunit). It is released under the
business-friendly Mozilla Public License, v. 2.0 and features the
functionality needed to realize continuous and automated testing of your
VHDL code. VUnit doesn't replace but rather complements traditional
testing methodologies by supporting a "test early and often" approach
through automation.

Interesting - another user of OSVVM too...

You may be interested to know that as of ghdl-0.32 (not yet released but
buildable from source for most systems : Mac OSX is giving a little
trouble), ghdl understands enough VHDL-2008 to support OSVVM. Should be
easy to integrate into Vunit...

https://sourceforge.net/projects/ghdl-updates/?source=navbar

-- Brian

@Brian Please join the VUnit with GHDL discussion on this thread: https://github.com/LarsAsplund/vunit/issues/10 Some requirements on GHDL are being discussed
 
On Thu, 19 Feb 2015 08:04:04 -0800, Lars Asplund wrote:

@Brian Please join the VUnit with GHDL discussion on this thread:
https://github.com/LarsAsplund/vunit/issues/10 Some requirements on GHDL
are being discussed

I'll have to subscribe to Github before I respond there.

Probably the best thing would be to file a ticket - enhancement request -
at
https://sourceforge.net/p/ghdl-updates/tickets/?source=navbar

It sounds like a reasonable facility to add.

Thanks
 
Den fredag 20 februari 2015 kl. 11:47:46 UTC+1 skrev Brian Drummond:
On Thu, 19 Feb 2015 08:04:04 -0800, Lars Asplund wrote:


@Brian Please join the VUnit with GHDL discussion on this thread:
https://github.com/LarsAsplund/vunit/issues/10 Some requirements on GHDL
are being discussed

I'll have to subscribe to Github before I respond there.

Probably the best thing would be to file a ticket - enhancement request -
at
https://sourceforge.net/p/ghdl-updates/tickets/?source=navbar

It sounds like a reasonable facility to add.

Thanks

Just my thought. I will do that.

/Lars
 
On Fri, 20 Feb 2015 03:51:54 -0800, Lars Asplund wrote:

Den fredag 20 februari 2015 kl. 11:47:46 UTC+1 skrev Brian Drummond:

Probably the best thing would be to file a ticket - enhancement request
It sounds like a reasonable facility to add.
Just my thought. I will do that.

and Tristan has agreed to add it...

-- Brian
 
Den lördag 21 februari 2015 kl. 13:33:03 UTC+1 skrev Brian Drummond:
On Fri, 20 Feb 2015 03:51:54 -0800, Lars Asplund wrote:

Den fredag 20 februari 2015 kl. 11:47:46 UTC+1 skrev Brian Drummond:

Probably the best thing would be to file a ticket - enhancement request
It sounds like a reasonable facility to add.
Just my thought. I will do that.

and Tristan has agreed to add it...

-- Brian

Great! Thanks.

Lars
 
We have now officially added VUnit support for GHDL.
Big thanks to Tristan who fixed many bugs and implemented some nice features for this to be possible.

I would like to recommend anyone who has not used GHDL for a while to take a look at it again as there have been major improvements and lots of VHDL 2008 support added lately.
 

Welcome to EDABoard.com

Sponsor

Back
Top