CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

OpenFOAM unit testing

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree1Likes
  • 1 Post By pbachant

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 7, 2015, 14:15
Default OpenFOAM unit testing
  #1
Senior Member
 
Pete Bachant
Join Date: Jun 2012
Location: Boston, MA
Posts: 173
Rep Power: 13
pbachant is on a distinguished road
Does anyone have any good ideas on how to write unit tests for OpenFOAM code? As far as I can tell, the OpenFOAM source sort of has unit tests in applications/test, but there appear to be no assertions, and no framework for building, calling and summarizing the tests. Is it better to simply write whole simulation cases and ensure these give the correct outputs? That option seems hard to automate.
HPE likes this.
__________________
Home | Twitter | GitHub
pbachant is offline   Reply With Quote

Old   November 7, 2015, 14:49
Default
  #2
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,974
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quick answers:
  1. There was an effort on this front I saw here on the forum, which you had commented on: http://www.cfd-online.com/Forums/ope...oam-mocks.html
  2. The closest to unit testing in OpenFOAM is currently:
  3. In foam-extend there is a bit more advanced unit testing, using CDash: http://openfoamwiki.net/index.php/Extend-testHarness - sorry, I'm still not familiar with who it does things, but that wiki page is very detailed!!
  4. In OpenFOAM a more dedicated unit test framework is pending sponsorship or contribution: http://www.openfoam.org/mantisbt/view.php?id=406
wyldckat is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Has no-one created unit tests for OpenFOAM with mocks? Kojirion OpenFOAM Programming & Development 2 August 31, 2015 17:11
OpenFOAM Foundation releases OpenFOAMŪ 2.3.1 CFDFoundation OpenFOAM Announcements from OpenFOAM Foundation 4 February 8, 2015 06:19
Can't get data from OpenFoam to external solver using externalCoupled perry OpenFOAM Running, Solving & CFD 4 May 26, 2014 09:09
[Gmsh] 2D Mesh Generation Tutorial for GMSH aeroslacker OpenFOAM Meshing & Mesh Conversion 12 January 19, 2012 04:52
Cross-compiling OpenFOAM 1.7.0 on Linux for Windows 32 and 64bits with Mingw-w64 wyldckat OpenFOAM Announcements from Other Sources 3 September 8, 2010 07:25


All times are GMT -4. The time now is 01:17.