CFD Online Logo CFD Online URL
Home > Forums > OpenFOAM Programming & Development

OpenFOAM unit testing

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

LinkBack Thread Tools Display Modes
Old   November 7, 2015, 14:15
Default OpenFOAM unit testing
Senior Member
Pete Bachant
Join Date: Jun 2012
Location: NH, USA
Posts: 167
Rep Power: 7
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
Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 9,978
Blog Entries: 39
Rep Power: 108
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 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:
  2. The closest to unit testing in OpenFOAM is currently:
  3. In foam-extend there is a bit more advanced unit testing, using CDash: - 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:
wyldckat is offline   Reply With Quote


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 11:43.