summaryrefslogtreecommitdiffstats
path: root/Makefile.am
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2014-07-07 21:16:01 +0200
committerJakub Hrozek <jhrozek@redhat.com>2014-07-08 20:28:01 +0200
commite592d5f157be869151983bd1b46d6f4f7a29daaf (patch)
tree06a9a6741fc7b0a429e43bc8d2a7b49269479d3e /Makefile.am
parentb1559c6498e791aa870f6e01948d1ad0f1af32e7 (diff)
downloadsssd-e592d5f157be869151983bd1b46d6f4f7a29daaf.tar.gz
sssd-e592d5f157be869151983bd1b46d6f4f7a29daaf.tar.xz
sssd-e592d5f157be869151983bd1b46d6f4f7a29daaf.zip
TESTS: Add a unit test for the sdap.c module
Covers the sdap_parse_entry function with unit tests so that we know that modifying the function in a later patch will not result in a regression. Reviewed-by: Michal Židek <mzidek@redhat.com>
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am33
1 files changed, 32 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index 1c423fc6d..c05d8cb5e 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -191,7 +191,9 @@ if HAVE_CMOCKA
responder-get-domains-tests \
sbus-internal-tests \
sss_sifp-tests \
- test_search_bases
+ test_search_bases \
+ sdap-tests \
+ $(NULL)
if BUILD_IFP
non_interactive_cmocka_based_tests += ifp_tests
@@ -1838,6 +1840,35 @@ dp_opt_tests_LDADD = \
$(SSSD_INTERNAL_LTLIBS) \
libsss_test_common.la
+sdap_tests_SOURCES = \
+ src/providers/data_provider_opts.c \
+ src/providers/ldap/sdap.c \
+ src/providers/ldap/sdap_range.c \
+ src/util/sss_ldap.c \
+ src/tests/cmocka/test_sdap.c \
+ $(NULL)
+sdap_tests_CFLAGS = \
+ $(AM_CFLAGS) \
+ $(SSS_CRYPT_CFLAGS) \
+ $(NULL)
+sdap_tests_LDFLAGS = \
+ -Wl,-wrap,ldap_set_option \
+ -Wl,-wrap,ldap_get_dn \
+ -Wl,-wrap,ldap_memfree \
+ -Wl,-wrap,ldap_get_values_len \
+ -Wl,-wrap,ldap_value_free_len \
+ -Wl,-wrap,ldap_first_attribute \
+ -Wl,-wrap,ldap_next_attribute \
+ $(NULL)
+sdap_tests_LDADD = \
+ $(CMOCKA_LIBS) \
+ $(TALLOC_LIBS) \
+ $(POPT_LIBS) \
+ $(SSSD_INTERNAL_LTLIBS) \
+ $(SSS_CRYPT_LIBS) \
+ libsss_test_common.la \
+ $(NULL)
+
if BUILD_IFP
ifp_tests_SOURCES = \
$(TEST_MOCK_RESP_OBJ) \