/[escript]/trunk/finley/test/SConscript
ViewVC logotype

Annotation of /trunk/finley/test/SConscript

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3078 - (hide annotations)
Tue Aug 3 03:12:16 2010 UTC (9 years, 1 month ago) by jfenwick
File size: 1366 byte(s)
Switched the build_dir keyword param to variant_dir.
Should fix issue 525.


1 ksteube 1811
2     ########################################################
3 ksteube 1705 #
4 jfenwick 2881 # Copyright (c) 2003-2010 by University of Queensland
5 ksteube 1811 # Earth Systems Science Computational Center (ESSCC)
6     # http://www.uq.edu.au/esscc
7 ksteube 1705 #
8 ksteube 1811 # Primary Business: Queensland, Australia
9     # Licensed under the Open Software License version 3.0
10     # http://www.opensource.org/licenses/osl-3.0.php
11 ksteube 1705 #
12 ksteube 1811 ########################################################
13 ksteube 1705
14 ksteube 1811
15 ksteube 1705 import os
16 robwdcock 649 Import('*')
17    
18 jfenwick 2231 local_env = clone_env(env_mpi)
19 robwdcock 649
20 gross 700 # get the relevant file names:
21 robwdcock 649 src_dir = local_env.Dir('.').srcnode().abspath
22 gross 700 filenames = [ x for x in os.listdir(src_dir) if os.path.splitext(x)[1] in [".h", ".c", ".cpp"] ]
23 robwdcock 649
24     sources = [x for x in filenames if os.path.splitext(x)[1] in ['.cpp', '.c']]
25    
26 ksteube 1705 local_env.Append(LIBS=['finley', 'escript', 'paso', 'esysUtils', 'CppUnitTest'] + env['sys_libs'])
27 robwdcock 668
28 gross 700 # compile test
29 ksteube 1705 program = local_env.Program('finley_UnitTest', sources)
30 robwdcock 670 env.Alias('build_tests', program)
31 robwdcock 649
32     # run the tests - but only if test_targets are stale
33 ksteube 1705 local_env.RunUnitTest('finley_UnitTest')
34     test_targets = os.path.splitext('finley_UnitTest')[0]+'.passed'
35 robwdcock 649 Alias("run_tests", test_targets)
36    
37 jfenwick 3078 CallSConscript(local_env,dirs = ['#/finley/test/python'], variant_dir='python', duplicate=0)
38 jfenwick 2239
39     # Add a group of tests
40     from grouptest import *
41 jfenwick 2249 tgroup=GroupTest("$BINRUNNER ", (),"","$BUILD_DIR/finley/test",('./finley_UnitTest',))
42 jfenwick 2239 TestGroups.append(tgroup)

  ViewVC Help
Powered by ViewVC 1.1.26