EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  <20212022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  <20212022  2023  2024 
<== Date ==> <== Thread ==>

Subject: RE: Unit testing IOCs and databases
From: Stainer Tom via Tech-talk <tech-talk at aps.anl.gov>
To: "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>
Date: Tue, 7 Sep 2021 11:19:01 +0000

Hi Ralph,

 

Thanks for the link, this is useful! I will take a look how to use this for other testing libraries.

 

With regard to base tests, I have indeed tried writing unit tests with the epicsUnitTest.h but one quirk I could not understand is why I have to count up all the asserts and add that number to the testPlan as an argument.

Do people run a script to count them or do you simply run it once to fail and then use that number?

It wasn’t a big issue, it is just a bit more overhead compared to other testing libraries.

 

I was also interested in using other output formats for reporting. I know epics-base can write junit files but I wanted something a bit finer grained, which I can get with other libraries.

 

Kind regards,

Tom

 

 

From: Tech-talk <tech-talk-bounces at aps.anl.gov> On Behalf Of Ralph Lange via Tech-talk
Sent: Tuesday, September 7, 2021 12:44 PM
To: EPICS Tech Talk <tech-talk at aps.anl.gov>
Subject: Re: Unit testing IOCs and databases

 

On Tue, 7 Sept 2021 at 11:13, Stainer Tom via Tech-talk <tech-talk at aps.anl.gov> wrote:

- Has anyone tried using other libraries, such as google test, Catch2, doctest,… to do unit testing in EPICS? If so, how can I set this up with the EPICS build system?

 

 

Base also has its own testing framework (standard C). The tests inside Base are probably the best example for that.

 

Cheers,
~Ralph 

 


Replies:
Re: Unit testing IOCs and databases Simon Rose via Tech-talk
Re: Unit testing IOCs and databases Johnson, Andrew N. via Tech-talk
References:
Unit testing IOCs and databases Stainer Tom via Tech-talk
Re: Unit testing IOCs and databases Ralph Lange via Tech-talk

Navigate by Date:
Prev: Re: Unit testing IOCs and databases Torsten Bögershausen via Tech-talk
Next: Re: Unit testing IOCs and databases Simon Rose via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  <20212022  2023  2024 
Navigate by Thread:
Prev: Re: Unit testing IOCs and databases Ralph Lange via Tech-talk
Next: Re: Unit testing IOCs and databases Simon Rose via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  <20212022  2023  2024 
ANJ, 07 Sep 2021 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·