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

OpenFOAM unit testing

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

Reply
 
LinkBack Thread Tools Display Modes
Old   November 7, 2015, 14:15
Default OpenFOAM unit testing
  #1
Senior Member
 
Pete Bachant
Join Date: Jun 2012
Location: NH, USA
Posts: 141
Rep Power: 6
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.
__________________
Home | Twitter | GitHub
pbachant is offline   Reply With Quote

Old   November 7, 2015, 14:49
Default
  #2
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 9,748
Blog Entries: 39
Rep Power: 103
wyldckat is a glorious beacon of lightwyldckat is a glorious beacon of lightwyldckat is a glorious beacon of lightwyldckat is a glorious beacon of lightwyldckat is a glorious beacon of light
Quick answers:
  1. There was an effort on this front I saw here on the forum, which you had commented on: Has no-one created unit tests for OpenFOAM with mocks?
  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
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 On
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 16: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 08:09
2D Mesh Generation Tutorial for GMSH aeroslacker Open Source Meshers: Gmsh, Netgen, CGNS, ... 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 06:25


All times are GMT -4. The time now is 07:20.