/[escript]/trunk/weipa/test/weipa_UnitTest.cpp
ViewVC logotype

Contents of /trunk/weipa/test/weipa_UnitTest.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 6939 - (show annotations)
Mon Jan 20 03:37:18 2020 UTC (22 months, 2 weeks ago) by uqaeller
File size: 1524 byte(s)
Updated the copyright header.


1
2 /*****************************************************************************
3 *
4 * Copyright (c) 2003-2020 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-2017 by Centre for Geoscience Computing (GeoComp)
14 * Development from 2019 by School of Earth and Environmental Sciences
15 **
16 *****************************************************************************/
17
18 #include <escript/EsysMPI.h>
19
20 #include "EscriptDatasetTestCase.h"
21
22 #include <cppunit/CompilerOutputter.h>
23 #include <cppunit/TestResult.h>
24 #include <cppunit/TestResultCollector.h>
25 #include <cppunit/TestRunner.h>
26
27 #include <iostream>
28
29 using namespace CppUnit;
30
31 int main(int argc, char* argv[])
32 {
33 #ifdef ESYS_MPI
34 int status = MPI_Init(&argc, &argv);
35 if (status != MPI_SUCCESS) {
36 std::cerr << argv[0] << ": MPI_Init failed, exiting." << std::endl;
37 return status;
38 }
39 #endif
40 TestResult controller;
41 TestResultCollector result;
42 controller.addListener(&result);
43 TestRunner runner;
44 runner.addTest(EscriptDatasetTestCase::suite());
45 runner.run(controller);
46 CompilerOutputter outputter( &result, std::cerr );
47 outputter.write();
48 #ifdef ESYS_MPI
49 MPI_Finalize();
50 #endif
51 return result.wasSuccessful() ? 0 : 1;
52 }
53

  ViewVC Help
Powered by ViewVC 1.1.26