/[escript]/trunk/escript/test/FunctionSpaceTestCase.cpp
ViewVC logotype

Annotation of /trunk/escript/test/FunctionSpaceTestCase.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 682 - (hide annotations)
Mon Mar 27 02:43:09 2006 UTC (13 years, 4 months ago) by robwdcock
File size: 2655 byte(s)
+ NEW BUILD SYSTEM

This commit contains the new build system with cross-platform support.
Most things work are before though you can have more control.

ENVIRONMENT settings have changed:
+ You no longer require LD_LIBRARY_PATH or PYTHONPATH to point to the
esysroot for building and testing performed via scons
+ ACcESS altix users: It is recommended you change your modules to load
the latest intel compiler and other libraries required by boost to match
the setup in svn (you can override). The correct modules are as follows

module load intel_cc.9.0.026
export
MODULEPATH=${MODULEPATH}:/data/raid2/toolspp4/modulefiles/gcc-3.3.6
module load boost/1.33.0/python-2.4.1
module load python/2.4.1
module load numarray/1.3.3


1 jgs 82 /*
2     *****************************************************************************
3     * *
4     * COPYRIGHT ACcESS - All Rights Reserved *
5     * *
6     * This software is the property of ACcESS. No part of this code *
7     * may be copied in any form or by any means without the expressed written *
8     * consent of ACcESS. Copying, use or modification of this software *
9     * by any unauthorised person is illegal unless that person has a software *
10     * license agreement with ACcESS. *
11     * *
12     *****************************************************************************
13     */
14 jgs 117
15 robwdcock 670 #include "escript/FunctionSpace.h"
16     #include "escript/NullDomain.h"
17 jgs 82
18     #include "FunctionSpaceTestCase.h"
19    
20     #include <iostream>
21     #include <sstream>
22    
23     using namespace CppUnitTest;
24     using namespace escript;
25     using namespace std;
26    
27     void FunctionSpaceTestCase::setUp() {
28     //
29     // This is called before each test is run
30    
31     }
32    
33     void FunctionSpaceTestCase::tearDown() {
34     //
35     // This is called after each test has been run
36    
37     }
38    
39     void FunctionSpaceTestCase::testAll() {
40     //
41     // The test code may be entered here
42     // There is nothing special about the function name, it may be renamed to
43     // something more suitable.
44     // As many test methods as desired may be added.
45    
46     cout << endl;
47    
48 jgs 117 cout << "\tTest default FunctionSpace constructor." << endl;
49    
50 jgs 82 // Test Default constructor
51 jgs 121 FunctionSpace testFunctionSpace0;
52 jgs 82 FunctionSpace testFunctionSpace1;
53    
54 jgs 121 assert(testFunctionSpace0==testFunctionSpace1);
55    
56 jgs 117 cout << "\tTest FunctionSpace constructor." << endl;
57    
58 jgs 82 // Test constructor
59     NullDomain nullDomain;
60     int testfunctionSpaceType = nullDomain.getFunctionCode();
61    
62     FunctionSpace testFunctionSpace2(nullDomain, testfunctionSpaceType);
63    
64 jgs 117 assert(testFunctionSpace1.getTypeCode()==testfunctionSpaceType);
65 jgs 82 assert(testFunctionSpace2.getDomain()==nullDomain);
66     assert(testFunctionSpace1.getDim()==1);
67     assert(testFunctionSpace1==testFunctionSpace1);
68     assert(!(testFunctionSpace1!=testFunctionSpace1));
69    
70     testFunctionSpace1=testFunctionSpace2;
71     assert(testFunctionSpace1==testFunctionSpace2);
72    
73     }
74    
75     TestSuite* FunctionSpaceTestCase::suite ()
76     {
77     //
78     // create the suite of tests to perform.
79     TestSuite *testSuite = new TestSuite ("FunctionSpaceTestCase");
80    
81     testSuite->addTest (new TestCaller< FunctionSpaceTestCase>("testAll",&FunctionSpaceTestCase::testAll));
82     return testSuite;
83     }

Properties

Name Value
svn:eol-style native
svn:keywords Author Date Id Revision

  ViewVC Help
Powered by ViewVC 1.1.26