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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 6511 - (show annotations)
Fri Mar 3 01:41:39 2017 UTC (2 years, 1 month ago) by jfenwick
File size: 1422 byte(s)
For some experiments

1
2 /*****************************************************************************
3 *
4 * Copyright (c) 2003-2016 by The University of Queensland
5 * http://www.uq.edu.au
6 *
7 * Primary Business: Queensland, Australia
8 * Licensed under the Apache License, version 2.0
9 * http://www.apache.org/licenses/LICENSE-2.0
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
17 #include <escript/EsysMPI.h>
18
19 #include "FinleyDomainTestCase.h"
20
21 #include <cppunit/CompilerOutputter.h>
22 #include <cppunit/TestResult.h>
23 #include <cppunit/TestResultCollector.h>
24 #include <cppunit/TestRunner.h>
25
26
27 using namespace CppUnit;
28
29 int main(int argc, char* argv[])
30 {
31 #ifdef ESYS_MPI
32 int status = MPI_Init(&argc, &argv);
33 if (status != MPI_SUCCESS) {
34 std::cerr << argv[0] << ": MPI_Init failed, exiting." << std::endl;
35 return status;
36 }
37 #endif
38 TestResult controller;
39 TestResultCollector result;
40 controller.addListener(&result);
41 TestRunner runner;
42 runner.addTest(FinleyDomainTestCase::suite());
43 runner.run(controller);
44 CompilerOutputter outputter(&result, std::cerr);
45 outputter.write();
46 #ifdef ESYS_MPI
47 MPI_Finalize();
48 #endif
49 return result.wasSuccessful() ? 0 : 1;
50 }
51

  ViewVC Help
Powered by ViewVC 1.1.26