/
SConscript
69 lines (57 loc) · 2.27 KB
/
SConscript
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
#
# Copyright (c) 2014 Juniper Networks, Inc. All rights reserved.
#
# -*- mode: python; -*-
import sys
if sys.platform == 'darwin':
Return()
import re
Import('AgentEnv')
env = AgentEnv.Clone()
# test specific modifications
AgentEnv.MakeTestEnv(env)
env.Append(CPPPATH = './')
env.Append(CPPPATH = '../')
env.Append(CPPPATH = ['../../../oper/test/'])
env.Append(CPPPATH = ['../../../test-xml/'])
env.Append(LIBPATH = ['./'])
env.Append(LIBPATH = ['../'])
env.Append(LIBPATH = ['../../../oper/test/'])
env.Append(LIBPATH = ['../../../test-xml/'])
env.Append(LIBS = [ 'control_node_mock'])
env.Prepend(LIBS = [ 'ovsdbclient', 'openvswitch'])
env.Prepend(LIBS = [ 'test_ovs_agent_init'])
env.Append(LIBS = ['ssl', 'crypto'])
env.Append(LIBS = [
'agent_test_xml',
'agent_oper_test_xml',
'agent_physical_devices_test_xml',
'agent_ovsdb_test_xml'])
env.Library('agent_ovsdb_test_xml', 'test_xml_ovsdb.cc')
TestSandeshGenFiles = env.SandeshGenCpp('test_ovsdb.sandesh')
TestSandeshGenSrcs = env.ExtractCpp(TestSandeshGenFiles)
test_sandesh_objs = AgentEnv.BuildExceptionCppObj(env, TestSandeshGenSrcs)
env.Library('test_ovs_agent_init',
test_sandesh_objs +
[
'test_ovs_agent_init.cc',
'test_ovs_agent_util.cc',
'test_ovsdb_sandesh.cc'
])
agent_suite = []
flaky_agent_suite = []
disabled_ovsdb_suite = []
test_ovs_route = AgentEnv.MakeTestCmd(env, 'test_ovs_route', flaky_agent_suite)
test_ovs_route = AgentEnv.MakeTestCmd(env, 'test_ovs_base', agent_suite)
test_ovs_route = AgentEnv.MakeTestCmd(env, 'test_ovs_logical_switch', agent_suite)
AgentEnv.MakeTestCmd(env, 'test_ovs_multicast_local', agent_suite)
AgentEnv.MakeTestCmd(env, 'test_ovs_unicast_remote', agent_suite)
AgentEnv.MakeTestCmd(env, 'test_ovs_unicast_local', agent_suite)
AgentEnv.MakeTestCmd(env, 'test_ovs_vlan_port', agent_suite)
AgentEnv.MakeTestCmd(env, 'test_agent_route_export', disabled_ovsdb_suite)
env.TestSuite('ovsdb_client:flaky_test', flaky_agent_suite)
flaky_test = env.TestSuite('agent-flaky-test', flaky_agent_suite)
env.TestSuite('ovsdb_client:test', agent_suite)
test = env.TestSuite('agent-test', agent_suite)
env.Alias('agent:agent_test', test)
Return('agent_suite')