blob: 2a41cd1b3e2baf70877445ff489836ce1f19e2eb [file] [log] [blame]
Shawn McCarney623f5a82019-11-03 08:55:40 -06001phosphor_regulators_tests_include_directories = include_directories(
2 '.',
3 'actions'
4)
5
Shawn McCarney6b2ebaf2019-11-04 12:12:19 -06006phosphor_regulators_tests_source_files = [
7 'device_tests.cpp',
8 'id_map_tests.cpp',
9 'rail_tests.cpp',
10 'rule_tests.cpp',
11
12 'actions/action_environment_tests.cpp',
Shawn McCarney8f0d1422020-02-02 15:54:47 -060013 'actions/action_error_tests.cpp',
Shawn McCarney78488f62019-11-05 15:29:54 -060014 'actions/action_utils_tests.cpp',
Shawn McCarney74538a62019-11-13 11:24:17 -060015 'actions/and_action_tests.cpp',
Shawn McCarney6d597732019-11-13 17:40:07 -060016 'actions/if_action_tests.cpp',
Shawn McCarney6aac4142019-11-12 19:47:13 -060017 'actions/not_action_tests.cpp',
Shawn McCarneyd3bbfe22019-11-13 13:53:20 -060018 'actions/or_action_tests.cpp',
Shawn McCarney2134ca62019-11-11 13:06:18 -060019 'actions/run_rule_action_tests.cpp',
Shawn McCarney6b2ebaf2019-11-04 12:12:19 -060020 'actions/set_device_action_tests.cpp'
21]
22
Shawn McCarneya2461b32019-10-24 18:53:01 -050023test('phosphor-regulators-tests',
24 executable('phosphor-regulators-tests',
Shawn McCarney6b2ebaf2019-11-04 12:12:19 -060025 phosphor_regulators_tests_source_files,
Shawn McCarneya2461b32019-10-24 18:53:01 -050026 dependencies: [
27 gmock,
28 gtest,
29 ],
Brandon Wymandc8e9312020-02-14 17:04:18 -060030 link_args: dynamic_linker,
31 build_rpath: get_option('oe-sdk').enabled() ? rpath : '',
Shawn McCarneyafb7fc32019-12-11 19:42:03 -060032 link_with: [
33 phosphor_regulators_library,
34 libi2c_dev_mock
35 ],
Shawn McCarneya2461b32019-10-24 18:53:01 -050036 implicit_include_directories: false,
Shawn McCarney623f5a82019-11-03 08:55:40 -060037 include_directories: [
38 phosphor_regulators_include_directories,
Shawn McCarneyafb7fc32019-12-11 19:42:03 -060039 phosphor_regulators_tests_include_directories,
40 libi2c_inc,
41 libi2c_dev_mock_inc
Shawn McCarney623f5a82019-11-03 08:55:40 -060042 ]
Shawn McCarneya2461b32019-10-24 18:53:01 -050043 )
44)