blob: ac47611b6582b195441dd9aa3d0afa86ae2916d4 [file] [log] [blame]
Radek Krejcib4ac5a92020-11-23 17:54:33 +01001
2include_directories(${CMAKE_CURRENT_SOURCE_DIR})
3
4set(format_sources
5 ${format_sources}
Radek Krejcib4ac5a92020-11-23 17:54:33 +01006 ${CMAKE_CURRENT_SOURCE_DIR}/*.h
Radek Iša56ca9e42020-09-08 18:42:00 +02007 ${CMAKE_CURRENT_SOURCE_DIR}/basic/*.c
Radek Krejcib4ac5a92020-11-23 17:54:33 +01008 ${CMAKE_CURRENT_SOURCE_DIR}/data/*.c
9 ${CMAKE_CURRENT_SOURCE_DIR}/extensions/*.c
10 ${CMAKE_CURRENT_SOURCE_DIR}/schema/*.c
Radek Išaa9ff2b82021-01-13 21:44:13 +010011 ${CMAKE_CURRENT_SOURCE_DIR}/types/*.c
Radek Iša59bf3272021-03-10 11:22:52 +010012 ${CMAKE_CURRENT_SOURCE_DIR}/restriction/*.c
Radek Išaa76902f2021-03-29 08:52:51 +020013 ${CMAKE_CURRENT_SOURCE_DIR}/node/*.c
Radek Krejcib4ac5a92020-11-23 17:54:33 +010014 PARENT_SCOPE)
15
Michal Vasko4a4bfe82021-09-01 14:22:32 +020016ly_add_utest(NAME uint8 SOURCES types/uint8.c)
17ly_add_utest(NAME uint16 SOURCES types/uint16.c)
18ly_add_utest(NAME uint32 SOURCES types/uint32.c)
19ly_add_utest(NAME uint64 SOURCES types/uint64.c)
Radek Išaa9ff2b82021-01-13 21:44:13 +010020ly_add_utest(NAME int8 SOURCES types/int8.c)
Michal Vasko4a4bfe82021-09-01 14:22:32 +020021ly_add_utest(NAME int16 SOURCES types/int16.c)
22ly_add_utest(NAME int32 SOURCES types/int32.c)
23ly_add_utest(NAME int64 SOURCES types/int64.c)
Radek Išaa3b653e2021-02-05 19:05:30 +010024ly_add_utest(NAME string SOURCES types/string.c)
Radek Išaded31052021-03-10 13:22:53 +010025ly_add_utest(NAME bits SOURCES types/bits.c)
Michal Vasko495f4502021-04-27 14:48:05 +020026ly_add_utest(NAME binary SOURCES types/binary.c)
Michal Vasko3e52de52021-04-13 13:45:55 +020027ly_add_utest(NAME inet_types SOURCES types/inet_types.c)
Michal Vaskode4a3412021-04-14 15:38:27 +020028ly_add_utest(NAME yang_types SOURCES types/yang_types.c)
aPieceka0319a12021-08-18 14:05:20 +020029ly_add_utest(NAME enumeration SOURCES types/enumeration.c)
aPiecek507562c2021-08-23 10:10:29 +020030ly_add_utest(NAME instanceid SOURCES types/instanceid.c)
Michal Vasko79a7a872022-06-17 09:00:48 +020031ly_add_utest(NAME instanceid_keys SOURCES types/instanceid_keys.c)
aPiecek3ecd4bf2021-08-23 15:01:57 +020032ly_add_utest(NAME union SOURCES types/union.c)
aPiecekea304e32021-08-18 09:13:47 +020033ly_add_utest(NAME boolean SOURCES types/boolean.c)
34ly_add_utest(NAME decimal64 SOURCES types/decimal64.c)
35ly_add_utest(NAME empty SOURCES types/empty.c)
36ly_add_utest(NAME identityref SOURCES types/identityref.c)
37ly_add_utest(NAME leafref SOURCES types/leafref.c)
Radek Išaa9ff2b82021-01-13 21:44:13 +010038
Radek Iša59bf3272021-03-10 11:22:52 +010039ly_add_utest(NAME range SOURCES restriction/test_range.c)
40ly_add_utest(NAME pattern SOURCES restriction/test_pattern.c)
41
Radek Išaa76902f2021-03-29 08:52:51 +020042ly_add_utest(NAME list SOURCES node/list.c)
43
Radek Iša56ca9e42020-09-08 18:42:00 +020044ly_add_utest(NAME common SOURCES basic/test_common.c)
45ly_add_utest(NAME set SOURCES basic/test_set.c)
46ly_add_utest(NAME hash_table SOURCES basic/test_hash_table.c)
47ly_add_utest(NAME inout SOURCES basic/test_inout.c)
48ly_add_utest(NAME context SOURCES basic/test_context.c)
Jan Kundrát323c3122021-12-14 11:44:57 +010049if(NOT WIN32)
Radek Krejci5902be92021-03-25 21:25:14 +010050ly_add_utest(NAME plugins SOURCES basic/test_plugins.c)
Jan Kundrát323c3122021-12-14 11:44:57 +010051endif()
Radek Iša56ca9e42020-09-08 18:42:00 +020052ly_add_utest(NAME xml SOURCES basic/test_xml.c)
53ly_add_utest(NAME json SOURCES basic/test_json.c)
54ly_add_utest(NAME xpath SOURCES basic/test_xpath.c)
55ly_add_utest(NAME yanglib SOURCES basic/test_yanglib.c)
56
Michal Vaskoc636ea42022-09-16 10:20:31 +020057ly_add_utest(NAME schema SOURCES schema/test_schema.c)
Michal Vasko12ef5362022-09-16 15:13:58 +020058ly_add_utest(NAME yang SOURCES schema/test_yang.c)
59ly_add_utest(NAME yin SOURCES schema/test_yin.c)
Radek Krejci18abde42020-06-13 20:04:39 +020060ly_add_utest(NAME tree_schema_compile SOURCES schema/test_tree_schema_compile.c)
aPiecek20ddf8b2021-01-08 11:50:37 +010061ly_add_utest(NAME printer_tree SOURCES schema/test_printer_tree.c)
Radek Iša56ca9e42020-09-08 18:42:00 +020062
Radek Krejci18abde42020-06-13 20:04:39 +020063ly_add_utest(NAME tree_data SOURCES data/test_tree_data.c)
64ly_add_utest(NAME new SOURCES data/test_new.c)
65ly_add_utest(NAME parser_xml SOURCES data/test_parser_xml.c)
66ly_add_utest(NAME printer_xml SOURCES data/test_printer_xml.c)
Radek Krejci1798aae2020-07-14 13:26:06 +020067ly_add_utest(NAME parser_json SOURCES data/test_parser_json.c)
Michal Vasko60ea6352020-06-29 13:39:39 +020068ly_add_utest(NAME lyb SOURCES data/test_lyb.c)
Radek Krejci18abde42020-06-13 20:04:39 +020069ly_add_utest(NAME validation SOURCES data/test_validation.c)
Michal Vasko4490d312020-06-16 13:08:55 +020070ly_add_utest(NAME merge SOURCES data/test_merge.c)
Michal Vaskoe893ddd2020-06-23 13:35:20 +020071ly_add_utest(NAME diff SOURCES data/test_diff.c)
Radek Iša56ca9e42020-09-08 18:42:00 +020072
Radek Krejci18abde42020-06-13 20:04:39 +020073ly_add_utest(NAME metadata SOURCES extensions/test_metadata.c)
74ly_add_utest(NAME nacm SOURCES extensions/test_nacm.c)
Radek Krejci038db942021-02-09 16:18:47 +010075ly_add_utest(NAME yangdata SOURCES extensions/test_yangdata.c)
tadeas-vintrlik2aa36b42021-11-03 13:07:34 +010076ly_add_utest(NAME schema_mount SOURCES extensions/test_schema_mount.c)
Michal Vaskoedb0fa52022-10-04 10:36:00 +020077ly_add_utest(NAME structure SOURCES extensions/test_structure.c)