/[escript]/branches/clazy/finley/test/finley_UnitTests.cpp
ViewVC logotype

Diff of /branches/clazy/finley/test/finley_UnitTests.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1388 by trankine, Fri Jan 11 07:45:58 2008 UTC revision 5593 by jfenwick, Fri Apr 24 01:36:26 2015 UTC
# Line 1  Line 1 
1    
2  /* $Id$ */  /*****************************************************************************
3    *
4    * Copyright (c) 2003-2015 by The University of Queensland
5    * http://www.uq.edu.au
6    *
7    * Primary Business: Queensland, Australia
8    * Licensed under the Open Software License version 3.0
9    * http://www.opensource.org/licenses/osl-3.0.php
10    *
11    * Development until 2012 by Earth Systems Science Computational Center (ESSCC)
12    * Development 2012-2013 by School of Earth Sciences
13    * Development from 2014 by Centre for Geoscience Computing (GeoComp)
14    *
15    *****************************************************************************/
16    
 /*******************************************************  
  *  
  *           Copyright 2003-2007 by ACceSS MNRF  
  *       Copyright 2007 by University of Queensland  
  *  
  *                http://esscc.uq.edu.au  
  *        Primary Business: Queensland, Australia  
  *  Licensed under the Open Software License version 3.0  
  *     http://www.opensource.org/licenses/osl-3.0.php  
  *  
  *******************************************************/  
17    
18  #include "MeshAdapterTestCase.h"  #include "MeshAdapterTestCase.h"
19    #include <cppunit/CompilerOutputter.h>
20    #include <cppunit/TestResult.h>
21    #include <cppunit/TestResultCollector.h>
22    #include <cppunit/TestRunner.h>
23    
 #include "tools/CppUnitTest/TestRunner.h"  
24    
25  using namespace CppUnitTest;  using namespace CppUnit;
26    
27  extern "C"{  #include "esysUtils/Esys_MPI.h"
 #include "paso/Paso_MPI.h"  
 }  
28    
29  int main(int argc, char* argv[])  int main(int argc, char* argv[])
30  {  {
31    #ifdef ESYS_MPI
32  #ifdef PASO_MPI      int status = MPI_Init(&argc, &argv);
33          int status = MPI_Init(&argc, &argv);      if (status != MPI_SUCCESS) {
34          if (status != MPI_SUCCESS) {          std::cerr << argv[0] << ": MPI_Init failed, exiting." << std::endl;
35            std::cerr << argv[0] << ": MPI_Init failed, exiting." << std::endl;          return status;
36            return status;      }
         }  
37  #endif  #endif
38        TestResult controller;
39          //      TestResultCollector result;
40          // object which runs all of the tests      controller.addListener(&result);
41          TestRunner runner;      TestRunner runner;
42          //      runner.addTest(MeshAdapterTestCase::suite());
43          // add the RangeTestCase suite of tests to the runner      runner.run(controller);
44          runner.addTest ("MeshAdapter", MeshAdapterTestCase::suite());      CompilerOutputter outputter( &result, std::cerr );
45        outputter.write();
46          // actually run the unit tests.  #ifdef ESYS_MPI
47          runner.run (argc, argv);      MPI_Finalize();
   
 #ifdef PASO_MPI  
         MPI_Finalize();  
48  #endif  #endif
49        return result.wasSuccessful() ? 0 : 1;
         return 0;  
50  }  }
51    

Legend:
Removed from v.1388  
changed lines
  Added in v.5593

  ViewVC Help
Powered by ViewVC 1.1.26