small adaptions to scons, fix a test
This commit is contained in:
parent
287fa11975
commit
b5d2e9486e
5 changed files with 15 additions and 7 deletions
|
|
@ -33,7 +33,7 @@ CUSTOPTIONSFILE = 'custom-options'
|
|||
SRCDIR = 'src'
|
||||
BINDIR = 'bin'
|
||||
TESTDIR = 'tests'
|
||||
VERSION = '3+alpha.01'
|
||||
VERSION = '0.1+pre.01'
|
||||
#-----------------------------------Configuration
|
||||
|
||||
# NOTE: scons -h for help.
|
||||
|
|
@ -68,6 +68,7 @@ def setupBasicEnvironment():
|
|||
RegisterPrecompiledHeader_Builder(env)
|
||||
handleNoBugSwitches(env)
|
||||
|
||||
env.Append(CPPDEFINES = '_GNU_SOURCE')
|
||||
appendCppDefine(env,'DEBUG','DEBUG', 'NDEBUG')
|
||||
appendCppDefine(env,'OPENGL','USE_OPENGL')
|
||||
appendVal(env,'ARCHFLAGS', 'CCFLAGS') # for both C and C++
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ out: caught error::Logic: LUMIERA_ERROR_FATAL:floundered (test-2).
|
|||
out: caught error::Invalid: LUMIERA_ERROR_INVALID:invalid input or parameters (test-3).
|
||||
out: caught lumiera::Error: LUMIERA_ERROR_EXTERNAL:failure in external service (test-4).
|
||||
out: caught std::runtime_error: test-5
|
||||
out: caught std::exception: std::exception
|
||||
out: caught std::exception. (unspecific)
|
||||
out: intermediate handler caught: LUMIERA_ERROR_EXTERNAL:failure in external service (test-7).....will rethrow as error::State
|
||||
out: caught lumiera::Error: LUMIERA_ERROR_STATE:unforseen state -- caused by: LUMIERA_ERROR_EXTERNAL:failure in external service (test-7).
|
||||
out: intermediate handler caught: LUMIERA_ERROR_EXTERNAL:failure in external service (test-8).....will rethrow as error::State
|
||||
|
|
|
|||
|
|
@ -9,6 +9,10 @@ from Buildhelper import globRootdirs
|
|||
|
||||
Import('env','artifacts','core')
|
||||
|
||||
# temp fix to add test.h -- wouldn't it be better to put this header be into src/lib ?
|
||||
env = env.Clone()
|
||||
env.Append(CPPPATH='#/.') # add Rootdir to Includepath, so test/test.h is found
|
||||
# temp fix-------------
|
||||
|
||||
def testExecutable(env,tree, exeName=None, obj=None):
|
||||
""" declare all targets needed to create a standalone
|
||||
|
|
@ -52,7 +56,7 @@ def treatPluginTestcase(env):
|
|||
moduledirs = globRootdirs('*')
|
||||
|
||||
# but have to treat some subdirs individually.
|
||||
specials = ['plugin','locking','library']
|
||||
specials = ['plugin','locking','library','backend']
|
||||
|
||||
|
||||
|
||||
|
|
@ -61,6 +65,10 @@ artifacts['testsuite'] = ts = ( [ testExecutable(env, dir) for dir in moduledirs
|
|||
+ testExecutable(env, 'locking', obj=['test-locking.c','mutex.c','condition.c'])
|
||||
+ testExecutable(env, 'library', exeName='test-llist', obj=['test-llist.c'])
|
||||
+ testExecutable(env, 'library', exeName='test-references', obj=['test-references.c'])
|
||||
+ testExecutable(env, 'library', exeName='test-safeclib', obj=['test-safeclib.c'])
|
||||
+ testExecutable(env, 'library', exeName='test-uuid', obj=['test-uuid.c'])
|
||||
+ testExecutable(env, 'backend', exeName='test-filedescriptors', obj=['test-filedescriptors.c'])
|
||||
+ testExecutable(env, 'backend', exeName='test-filehandles', obj=['test-filehandles.c'])
|
||||
)
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -97,7 +97,7 @@ namespace lumiera
|
|||
void throwInvalid (string _) { throw error::Invalid(_); }
|
||||
void throwExternal(string _) { throw error::External(_); }
|
||||
void throwRuntime (string _) { throw std::runtime_error(_); }
|
||||
void throwExceptn (string _) { throw std::exception(error::State(_)); }
|
||||
void throwExceptn (string _) { throw std::exception(); }
|
||||
|
||||
|
||||
/** @test catching, repackaging and rethrowing of errors.
|
||||
|
|
@ -219,7 +219,7 @@ namespace lumiera
|
|||
catch (error::Invalid&e) { cout << "caught error::Invalid: " << e.what() << "\n"; }
|
||||
catch (Error& e) { cout << "caught lumiera::Error: " << e.what() << "\n"; }
|
||||
catch (runtime_error& e) { cout << "caught std::runtime_error: " << e.what() << "\n"; }
|
||||
catch (exception& e) { cout << "caught std::exception: " << e.what() << "\n"; }
|
||||
catch (exception& e) { cout << "caught std::exception. (unspecific)" << "\n"; }
|
||||
catch (...) { cout << "caught an unknown exception\n"; }
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
#!/bin/bash
|
||||
# Copyright (C) Lumiera.org
|
||||
# 2007, Christian Thaeter <ct@pipapo.org>
|
||||
# Hermann Vosseler <Ichthyostega@web.de>
|
||||
# 2007 - 2008, Christian Thaeter <ct@pipapo.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
|
|
|
|||
Loading…
Reference in a new issue