src_dir = env.get('SRC_DIR')
targets_need_gtest = ['darwin','linux']
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
-gtest_zip_file = src_dir + '/extlibs/gtest/gtest-1.7.0.zip'
+gtest_dir = os.path.join(src_dir, 'extlibs', 'gtest', 'gtest-1.7.0')
+gtest_zip_file = os.path.join(src_dir, 'extlibs', 'gtest', 'gtest-1.7.0.zip')
gtest_url = 'https://googletest.googlecode.com/files/gtest-1.7.0.zip'
if target_os in targets_need_gtest:
# Run configure on gtest
print 'Configuring google unit test'
if env.get('CROSS_COMPILE'):
- env.Configure(gtest_dir, './configure --host=' + env['CROSS_COMPILE'])
+ env.Configure(gtest_dir, './configure --disable-shared --host=' + env['CROSS_COMPILE']);
else:
- env.Configure(gtest_dir, './configure')
+ env.Configure(gtest_dir, './configure --disable-shared')
# Run make on gtest
print 'Making google unit test'
env.Configure(gtest_dir, 'make')
+env.AppendUnique(LIBPATH = [ os.path.join(gtest_dir , 'lib', '.libs')])
+env.PrependUnique(CPPPATH = [ os.path.join(gtest_dir, 'include')])
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
+
Import('env')
import os
import os.path
######################################################################
unittests_env.PrependUnique(CPPPATH = [
os.path.join(pi_dir, 'include'),
- '#extlibs/gtest/gtest-1.7.0/include',
])
unittests_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
unittests_env.PrependUnique(LIBS = ['-lpthread'])
unittests_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-unittests_env.AppendUnique(LIBPATH = [os.path.join(src_dir, 'extlibs', 'gtest', 'gtest-1.7.0', 'lib', '.libs')])
unittests_env.PrependUnique(LIBS = [
'plugin_interface',
'oc',
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
+
Import('env')
import os
import os.path
'../include',
'../../logger/include',
'../../../oc_logger/include',
- '../../../../extlibs/gtest/gtest-1.7.0/include'
])
randomtest_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
randomtest_env.AppendUnique(LIBS = ['-lpthread'])
randomtest_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-randomtest_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
randomtest_env.PrependUnique(LIBS = ['m',
'octbstack',
'uuid',
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
Import('env')
import os
# Build flags
######################################################################
malloctest_env.PrependUnique(CPPPATH = [
- '../include',
- '#extlibs/gtest/gtest-1.7.0/include' ])
+ '../include'])
malloctest_env.AppendUnique(LIBPATH = [os.path.join(env.get('BUILD_DIR'), 'resource/c_common')])
-malloctest_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
malloctest_env.PrependUnique(LIBS = ['c_common', 'gtest', 'gtest_main', 'pthread'])
if env.get('LOGGING'):
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
-
+SConscript('#extlibs/gtest/SConscript')
Import('env')
import os
# Build flags
######################################################################
stringtest_env.PrependUnique(CPPPATH = [
- '../include',
- '#extlibs/gtest/gtest-1.7.0/include' ])
+ '../include'])
stringtest_env.AppendUnique(LIBPATH = [os.path.join(env.get('BUILD_DIR'), 'resource/c_common')])
-stringtest_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
stringtest_env.PrependUnique(LIBS = ['c_common', 'gtest', 'gtest_main', 'pthread'])
if env.get('LOGGING'):
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
-
+SConscript('#extlibs/gtest/SConscript')
Import('env')
import os
# Build flags
######################################################################
timetest_env.PrependUnique(CPPPATH = [
- '../include',
- '#extlibs/gtest/gtest-1.7.0/include' ])
+ '../include'])
timetest_env.AppendUnique(LIBPATH = [os.path.join(env.get('BUILD_DIR'), 'resource/c_common')])
-timetest_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
timetest_env.PrependUnique(LIBS = ['c_common', 'gtest', 'gtest_main', 'pthread'])
timetest_env.Append(LIBS = ['rt']);
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
+
Import('env')
import os
import os.path
'../../stack/include',
'../../extlibs/cjson',
'../../../oc_logger/include',
- '../../../../extlibs/gtest/gtest-1.7.0/include'
])
tmplist = catest_env['LINKFLAGS'][:]
catest_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
catest_env.AppendUnique(LIBS = ['pthread'])
catest_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-catest_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
catest_env.PrependUnique(LIBS = ['m',
'octbstack',
'connectivity_abstraction',
# //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
#
# SConscript file for Local PKI google tests
+SConscript('#extlibs/gtest/SConscript')
Import('env')
'../../../../logger/include',
'../../../../stack/include',
'../../../../../oc_logger/include',
- '../../../../../../extlibs/gtest/gtest-1.7.0/include',
'../../../../../../extlibs/asn1cert',
'../../../../../../extlibs/tinydtls',
'../../../../../../extlibs/tinydtls/ecc',
pki_test_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
pki_test_env.AppendUnique(LIBS = ['pthread'])
pki_test_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-pki_test_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
pki_test_env.AppendUnique(LIBS = ['octbstack'])
pki_test_env.AppendUnique(LIBS = ['CKManager'])
os.makedirs(result_dir)
pki_test_env.AppendENVPath('GTEST_OUTPUT', ['xml:'+ result_dir])
pki_test_env.AppendENVPath('LD_LIBRARY_PATH', [out_dir])
- pki_test_env.AppendENVPath('LD_LIBRARY_PATH', [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
ut = pki_test_env.Command ('ut', None, out_dir + '/resource/csdk/security/unittest/unittest')
AlwaysBuild ('ut')
# //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
#
+SConscript('#extlibs/gtest/SConscript')
+
Import('env')
import os
import os.path
'../../../logger/include',
'../../../stack/include',
'../../../../oc_logger/include',
- '../../../../../extlibs/gtest/gtest-1.7.0/include',
'../include',
'../include/internal'
])
sptest_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
sptest_env.AppendUnique(LIBS = ['-lpthread','-ldl'])
sptest_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-sptest_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
sptest_env.PrependUnique(LIBS = [ 'ocpmapi',
'oc',
'ocsrm',
os.makedirs(result_dir)
sptest_env.AppendENVPath('GTEST_OUTPUT', ['xml:'+ result_dir])
sptest_env.AppendENVPath('LD_LIBRARY_PATH', [out_dir])
- sptest_env.AppendENVPath('LD_LIBRARY_PATH', ['./extlibs/gtest/gtest-1.7.0/lib/.libs'])
ut = sptest_env.Command ('ut', None, out_dir + '/resource/csdk/security/provisioning/unittest/unittest')
AlwaysBuild ('ut')
# //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
#
+SConscript('#extlibs/gtest/SConscript')
+
Import('env')
import os
import os.path
'../../stack/include',
'../../stack/include/internal',
'../../../oc_logger/include',
- '../../../../extlibs/gtest/gtest-1.7.0/include',
'../../../../extlibs/cjson/',
'../provisioning/include',
# '../../../../extlibs/tinydtls/',
srmtest_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
srmtest_env.AppendUnique(LIBS = ['-lpthread'])
srmtest_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-srmtest_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
srmtest_env.PrependUnique(LIBS = ['ocsrm',
'octbstack',
'oc_logger',
os.makedirs(result_dir)
srmtest_env.AppendENVPath('GTEST_OUTPUT', ['xml:'+ result_dir])
srmtest_env.AppendENVPath('LD_LIBRARY_PATH', [out_dir])
- srmtest_env.AppendENVPath('LD_LIBRARY_PATH', ['./extlibs/gtest/gtest-1.7.0/lib/.libs'])
- ut = srmtest_env.Command ('ut', None, out_dir + '/resource/csdk/security/unittest/unittest')
- AlwaysBuild ('ut')
+ from tools.scons.RunTest import *
+ run_test(srmtest_env,'ut','resource/csdk/security/unittest/unittest')
+
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
+
Import('env')
import os
import os.path
'../../connectivity/external/inc',
'../../extlibs/cjson',
'../../../oc_logger/include',
- '#extlibs/gtest/gtest-1.7.0/include'
])
stacktest_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
stacktest_env.AppendUnique(LIBS = ['-lpthread'])
stacktest_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-stacktest_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
stacktest_env.PrependUnique(LIBS = ['m',
'octbstack',
'ocsrm',
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
+
Import('env')
import os
import os.path
'../../csdk/ocsocket/include',
'../../csdk/ocrandom/include',
'../../csdk/logger/include',
- '../../../extlibs/gtest/gtest-1.7.0/include',
'../../../extlibs/hippomocks-master/HippoMocks',
'../../../extlibs/hippomocks-master/HippoMocksTest'
])
provisiontests_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
provisiontests_env.AppendUnique(LIBS = ['-lpthread', '-ldl'])
provisiontests_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-provisiontests_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
provisiontests_env.PrependUnique(LIBS = [
'ocprovision',
'oc',
os.makedirs(result_dir)
provisiontests_env.AppendENVPath('GTEST_OUTPUT', ['xml:'+ result_dir])
provisiontests_env.AppendENVPath('LD_LIBRARY_PATH', [out_dir])
- provisiontests_env.AppendENVPath('LD_LIBRARY_PATH', ['./extlibs/gtest/gtest-1.7.0/lib/.libs'])
ut = provisiontests_env.Command ('ut', None, out_dir + 'resource/provisioning/unittests/provisiontests')
AlwaysBuild ('ut')
# 'unit_test' script for building unit tests and libs
#
##
-
+SConscript('#extlibs/gtest/SConscript')
Import('env')
target_os = env.get('TARGET_OS')
build_dir = env.get('BUILD_DIR')
if target_os == 'linux':
- # Verify that 'google unit test' library is installed. If not,
- # get it and install it
- SConscript(src_dir + '/extlibs/gtest/SConscript')
-
# Verify that 'hippomocks' mocking code is installed. If not,
# get it and install it
SConscript(src_dir + '/extlibs/hippomocks.scons')
SConscript('provisioning/unittests/SConscript')
elif target_os == 'darwin':
- # Verify that 'google unit test' library is installed. If not,
- # get it and install it
- SConscript(src_dir + '/extlibs/gtest/SConscript')
-
# Build C stack's unit tests.
SConscript('csdk/stack/test/SConscript')
SConscript('csdk/connectivity/test/SConscript')
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
Import('env')
import os
import os.path
'../csdk/ocsocket/include',
'../c_common/ocrandom/include',
'../csdk/logger/include',
- '#extlibs/gtest/gtest-1.7.0/include',
'#extlibs/hippomocks-master/HippoMocks',
'#extlibs/hippomocks-master/HippoMocksTest'
])
unittests_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
unittests_env.AppendUnique(LIBS = ['-lpthread'])
unittests_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-unittests_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
unittests_env.PrependUnique(LIBS = [
'oc',
'octbstack',
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
+
Import('env')
import os
import os.path
######################################################################
enrollee_test_env.PrependUnique(CPPPATH = [
- enrollee_test_env.get('SRC_DIR') + '/extlibs/gtest/gtest-1.7.0/include',
enrollee_test_env.get('SRC_DIR') + '/resource/c_common/ocrandom/include',
enrollee_test_env.get('SRC_DIR') + '/resource/csdk/stack/include/internal',
enrollee_test_env.get('SRC_DIR') + '/resource/csdk/connectivity/api',
enrollee_test_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-pthread'])
enrollee_test_env.AppendUnique(LIBS = ['-lpthread'])
enrollee_test_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-enrollee_test_env.AppendUnique(LIBPATH = [src_dir + '/extlibs/gtest/gtest-1.7.0/lib/.libs'])
enrollee_test_env.PrependUnique(LIBS = ['m',
'octbstack',
'ocsrm',
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# Mediator[CSDK] Unit Test build script
##
target_os = env.get('TARGET_OS')
if target_os == 'linux':
- # Verify that 'google unit test' library is installed. If not,
- # get it and install it
- SConscript(env.get('SRC_DIR') + '/extlibs/gtest/SConscript')
-
# Verify that 'hippomocks' mocking code is installed. If not,
# get it and install it
SConscript(env.get('SRC_DIR') + '/extlibs/hippomocks.scons')
#unit test setting
######################################################################
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
######################################################################
# Build flags
######################################################################
-gtest = File(gtest_dir + '/lib/.libs/libgtest.a')
-gtest_main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
mediator_csdk_test_env.AppendUnique(
CPPPATH = [
src_dir + '/extlibs/hippomocks-master',
- src_dir + '/extlibs/gtest/gtest-1.7.0/include',
'../inc',
'../../../inc',
])
'oc_logger',
'oc_logger_core',
'connectivity_abstraction',
- gtest,
- gtest_main])
+ 'gtest',
+ 'gtest_main'])
mediator_csdk_test_env.AppendUnique(LIBS = ['dl'])
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# Mediator[RichSDK] Unit Test build script
target_os = env.get('TARGET_OS')
if target_os == 'linux':
- # Verify that 'google unit test' library is installed. If not,
- # get it and install it
- SConscript(env.get('SRC_DIR') + '/extlibs/gtest/SConscript')
-
# Verify that 'hippomocks' mocking code is installed. If not,
# get it and install it
SConscript(env.get('SRC_DIR') + '/extlibs/hippomocks.scons')
#unit test setting
######################################################################
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
######################################################################
# Build flags
######################################################################
-gtest = File(gtest_dir + '/lib/.libs/libgtest.a')
-gtest_main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
mediator_rich_test_env.AppendUnique(
CPPPATH = [
src_dir + '/extlibs/hippomocks-master',
- src_dir + '/extlibs/gtest/gtest-1.7.0/include',
'../inc',
'../../../inc',
])
'oc',
'octbstack',
'oc_logger',
- gtest,
- gtest_main])
+ 'gtest',
+ 'gtest_main'])
+
mediator_rich_test_env.AppendUnique(LIBS = ['dl'])
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# ResourceContainer (rcs_container) Unit Test build script
######################### unit test setting ##########################
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
######################################################################
######################################################################
# Build flags
######################################################################
-gtest = File(gtest_dir + '/lib/.libs/libgtest.a')
-gtest_main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
-
container_gtest_env.AppendUnique(
CPPPATH = [
env.get('SRC_DIR')+'/extlibs',
container_gtest_env.AppendUnique(CXXFLAGS = ['-frtti', '-fexceptions'])
container_gtest_env.PrependUnique(LIBS = ['gnustl_shared', 'compatibility', 'log'])
-container_gtest_env.PrependUnique(CPPPATH = [env.get('SRC_DIR')+'/extlibs/hippomocks-master',
- gtest_dir + '/include'])
+container_gtest_env.PrependUnique(CPPPATH = [env.get('SRC_DIR')+'/extlibs/hippomocks-master'])
if int(containerJavaSupport):
try:
container_gtest_env.AppendUnique(CCFLAGS = ['-Wnoexcept'])
-container_gtest_env.PrependUnique(LIBS = ['rcs_container', 'rcs_client', 'rcs_server', 'rcs_common', 'oc','octbstack', 'oc_logger', 'oc_logger_core', 'connectivity_abstraction', gtest, gtest_main])
+container_gtest_env.PrependUnique(LIBS = ['rcs_container', 'rcs_client', 'rcs_server', 'rcs_common', 'oc','octbstack', 'oc_logger', 'oc_logger_core', 'connectivity_abstraction', 'gtest', 'gtest_main'])
container_gtest_env.AppendUnique(LIBS = ['dl'])
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# rcs_common (primitiveResource and expiryTimer) build script
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
-
rcs_common_env = lib_env.Clone()
target_os = env.get('TARGET_OS')
rcs_common_test_env.PrependUnique(CPPPATH = [
env.get('SRC_DIR')+'/extlibs/hippomocks-master',
- gtest_dir + '/include',
'utils/include'
])
- gtest = File(gtest_dir + '/lib/.libs/libgtest.a')
- gtest_main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
-
rcs_common_test_env.PrependUnique(LIBS = [
'octbstack',
'oc_logger',
'connectivity_abstraction',
'coap',
'rcs_common',
- gtest,
- gtest_main,
+ 'gtest',
+ 'gtest_main',
'pthread'
])
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# ResourceBroker Unit Test build script
#unit test setting
######################################################################
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
broker_test_env = lib_env.Clone()
target_os = env.get('TARGET_OS')
######################################################################
# Build flags
######################################################################
-gtest = File(gtest_dir + '/lib/.libs/libgtest.a')
-gtest_main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
broker_test_env.AppendUnique(CPPPATH = ['../include'])
broker_test_env.AppendUnique(CPPPATH = ['../../../include'])
broker_test_env.AppendUnique(CPPPATH = ['../../common/expiryTimer/src'])
broker_test_env.AppendUnique(CPPPATH = ['../../common/utils/include'])
-broker_test_env.PrependUnique(CPPPATH = [env.get('SRC_DIR')+'/extlibs/hippomocks-master',
- gtest_dir + '/include'])
+broker_test_env.PrependUnique(CPPPATH = [env.get('SRC_DIR')+'/extlibs/hippomocks-master'])
broker_test_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
broker_test_env.PrependUnique(LIBS = ['coap'])
broker_test_env.AppendUnique(LIBS = ['oc'])
broker_test_env.AppendUnique(LIBS = ['rcs_client'])
broker_test_env.AppendUnique(LIBS = ['rcs_common'])
-broker_test_env.AppendUnique(LIBS = [gtest])
-broker_test_env.AppendUnique(LIBS = [gtest_main])
+broker_test_env.AppendUnique(LIBS = ['gtest'])
+broker_test_env.AppendUnique(LIBS = ['gtest_main'])
if target_os not in ['windows', 'winrt']:
broker_test_env.AppendUnique(CXXFLAGS = ['-O2', '-g', '-Wall', '-fmessage-length=0', '-std=c++0x'])
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# ResourceCache Unit Test build script
# unit test setting
######################################################################
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
cache_test_env = lib_env.Clone()
target_os = env.get('TARGET_OS')
######################################################################
# Build flags
######################################################################
-gtest = File(gtest_dir + '/lib/.libs/libgtest.a')
-gtest_main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
cache_test_env.AppendUnique(CPPPATH = ['../include'])
cache_test_env.AppendUnique(CPPPATH = ['../../../include'])
cache_test_env.AppendUnique(CPPPATH = ['../../common/expiryTimer/include'])
cache_test_env.AppendUnique(CPPPATH = ['../../common/expiryTimer/src'])
cache_test_env.AppendUnique(CPPPATH = ['../../common/utils/include'])
-cache_test_env.PrependUnique(CPPPATH = [env.get('SRC_DIR')+'/extlibs/hippomocks-master',
- gtest_dir + '/include'])
+cache_test_env.PrependUnique(CPPPATH = [env.get('SRC_DIR')+'/extlibs/hippomocks-master'])
cache_test_env.AppendUnique(LIBPATH = [env.get('BUILD_DIR')])
-cache_test_env.PrependUnique(LIBS = ['rcs_client', 'rcs_common', 'oc', 'octbstack', 'oc_logger', 'connectivity_abstraction', 'coap', gtest, gtest_main])
+cache_test_env.PrependUnique(LIBS = ['rcs_client', 'rcs_common', 'oc', 'octbstack', 'oc_logger', 'connectivity_abstraction', 'coap', 'gtest', 'gtest_main'])
if target_os not in ['windows', 'winrt']:
cache_test_env.AppendUnique(CXXFLAGS = ['-O2', '-g', '-Wall', '-fmessage-length=0', '-std=c++0x'])
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# rcs_server (Server Builder) project build script
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
-
server_builder_env = lib_env.Clone()
target_os = env.get('TARGET_OS')
server_builder_test_env.AppendUnique(CPPPATH = [
env.get('SRC_DIR')+'/extlibs/hippomocks-master',
- gtest_dir + '/include',
'../common/utils/include'
])
- gtest = File(gtest_dir + '/lib/.libs/libgtest.a')
- gtest_main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
-
server_builder_test_env.PrependUnique(LIBS = [
'rcs_server',
'octbstack',
'oc_logger',
'connectivity_abstraction',
'coap',
- gtest,
- gtest_main,
+ 'gtest',
+ 'gtest_main',
'pthread',
])
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# ResourceClient Unit Test build script
target_os = env.get('TARGET_OS')
if target_os == 'linux':
- # Verify that 'google unit test' library is installed. If not,
- # get it and install it
- SConscript(env.get('SRC_DIR') + '/extlibs/gtest/SConscript')
-
# Verify that 'hippomocks' mocking code is installed. If not,
# get it and install it
SConscript(env.get('SRC_DIR') + '/extlibs/hippomocks.scons')
#unit test setting
######################################################################
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
######################################################################
# Build flags
######################################################################
-gtest = File(gtest_dir + '/lib/.libs/libgtest.a')
-gtest_main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
-
rcs_test_env.AppendUnique(
CPPPATH = [
src_dir + '/extlibs/hippomocks-master',
- src_dir + '/extlibs/gtest/gtest-1.7.0/include',
'../include',
'../src/common/utils/include',
])
'rcs_client',
'rcs_server',
'rcs_common',
- gtest,
- gtest_main])
+ 'gtest',
+ 'gtest_main'])
rcs_test_env.AppendUnique(LIBS = ['dl'])
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# ResourceHosting Unit Test build script
#unit test setting
######################################################################
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
hosting_test_env = lib_env.Clone()
target_os = env.get('TARGET_OS')
######################################################################
# Build flags
######################################################################
-GTest = File(gtest_dir + '/lib/.libs/libgtest.a')
-GTest_Main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
-#hosting_test_env.AppendUnique(LIBPATH = [gtest_dir + '/lib/.libs'])
hosting_test_env.AppendUnique(LIBPATH = [lib_env.get('BUILD_DIR')])
hosting_test_env.AppendUnique(LIBS = [
'resource_hosting', 'rcs_server', 'rcs_client','rcs_common',
'oc', 'octbstack', 'oc_logger', 'connectivity_abstraction', 'coap',
- GTest_Main, GTest])
+ 'gtest_main', 'gtest'])
if target_os not in ['windows', 'winrt']:
hosting_test_env.AppendUnique(CXXFLAGS = ['-O2', '-g', '-Wall', '-fmessage-length=0', '-std=c++0x'])
hosting_test_env.AppendUnique(CXXFLAGS = ['-pthread'])
hosting_test_env.AppendUnique(LIBS = ['pthread'])
-hosting_test_env.PrependUnique(CPPPATH = [ src_dir + '/extlibs/hippomocks-master',
- gtest_dir + '/include'])
+hosting_test_env.PrependUnique(CPPPATH = [ src_dir + '/extlibs/hippomocks-master'])
hosting_test_env.AppendUnique(CPPPATH = ['../src'])
hosting_test_env.AppendUnique(CPPPATH = ['../../resource-encapsulation/include'])
hosting_test_env.AppendUnique(CPPPATH = ['../../resource-encapsulation/src/common/primitiveResource/include'])
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
+
##
# SceneManager Unit Test build script
##
#unit test setting
######################################################################
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
scene_test_env = lib_env.Clone()
target_os = env.get('TARGET_OS')
######################################################################
# Build flags
######################################################################
-GTest = File(gtest_dir + '/lib/.libs/libgtest.a')
-GTest_Main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
-#scene_test_env.AppendUnique(LIBPATH = [gtest_dir + '/lib/.libs'])
scene_test_env.AppendUnique(LIBPATH = [lib_env.get('BUILD_DIR')])
scene_test_env.AppendUnique(LIBS = [
'scene_manager', 'rcs_server', 'rcs_client','rcs_common',
'oc', 'octbstack', 'oc_logger', 'connectivity_abstraction', 'coap',
- GTest_Main, GTest])
+ 'gtest_main', 'gtest'])
if target_os not in ['windows', 'winrt']:
scene_test_env.AppendUnique(CXXFLAGS = ['-O2', '-g', '-Wall', '-fmessage-length=0', '-std=c++0x'])
scene_test_env.PrependUnique(LIBS = ['gcov'])
scene_test_env.AppendUnique(CXXFLAGS = ['--coverage'])
-scene_test_env.PrependUnique(CPPPATH = [ src_dir + '/extlibs/hippomocks-master',
- gtest_dir + '/include'])
+scene_test_env.PrependUnique(CPPPATH = [ src_dir + '/extlibs/hippomocks-master'])
scene_test_env.AppendUnique(CPPPATH = ['../include'])
scene_test_env.AppendUnique(CPPPATH = ['../src'])
scene_test_env.AppendUnique(CPPPATH = ['../../resource-encapsulation/include'])
# limitations under the License.
#
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+SConscript('#extlibs/gtest/SConscript')
##
# ThingsManager Unit Test build script
target_os = env.get('TARGET_OS')
if target_os == 'linux':
- # Verify that 'google unit test' library is installed. If not,
- # get it and install it
- SConscript(env.get('SRC_DIR') + '/extlibs/gtest/SConscript')
-
# Verify that 'hippomocks' mocking code is installed. If not,
# get it and install it
SConscript(env.get('SRC_DIR') + '/extlibs/hippomocks.scons')
#unit test setting
######################################################################
src_dir = lib_env.get('SRC_DIR')
-gtest_dir = src_dir + '/extlibs/gtest/gtest-1.7.0'
######################################################################
# Build flags
######################################################################
-gtest = File(gtest_dir + '/lib/.libs/libgtest.a')
-gtest_main = File(gtest_dir + '/lib/.libs/libgtest_main.a')
-
ThingsManager_gtest_env.AppendUnique(
CPPPATH = [
src_dir + '/extlibs/hippomocks-master',
- src_dir + '/extlibs/gtest/gtest-1.7.0/include',
'../sdk/inc',
'../../../extlibs/timer'
])
'oc_logger_core',
'oc',
'octbstack',
- gtest,
- gtest_main])
+ 'gtest',
+ 'gtest_main'])
ThingsManager_gtest_env.AppendUnique(LIBS = ['dl'])