On Mon, May 19, 2014 at 09:34:58AM +0200, Lukas Slebodnik wrote:
ehlo,
patch is attached.
LS
From 159e5434e4f175bd309b652d6e305d4a3c1c6f06 Mon Sep 17 00:00:00 2001 From: Lukas Slebodnik lslebodn@redhat.com Date: Sat, 17 May 2014 16:18:32 +0200 Subject: [PATCH] TEST: Test an empty results from functions sysdb_search_*
src/tests/sysdb-tests.c | 137 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+)
diff --git a/src/tests/sysdb-tests.c b/src/tests/sysdb-tests.c index 3e4d5f7f0f4e7ba887fab8ccf00d4f89771776f0..4b03f0bd669af522a8b9f44d4bc785e2c28c0492 100644 --- a/src/tests/sysdb-tests.c +++ b/src/tests/sysdb-tests.c @@ -4411,6 +4411,140 @@ START_TEST(test_sysdb_attrs_get_string_array) } END_TEST
+START_TEST (test_sysdb_search_return_ENOENT) +{
- struct sysdb_test_ctx *test_ctx;
- int ret;
- struct ldb_dn *user_dn = NULL;
- struct ldb_message *msg = NULL;
- struct ldb_message **msgs = NULL;
- struct ldb_result *res = NULL;
- size_t count;
- //const char *attrs[] = { SYSDB_NAME, NULL };
You should remove the comment.
- /* Setup */
- ret = setup_sysdb_tests(&test_ctx);
- fail_if(ret != EOK, "Could not set up the test");
- /* Search user */
- ret = sysdb_search_user_by_name(test_ctx, test_ctx->domain,
"nonexisting_user", NULL, &msg);
- fail_unless(ret == ENOENT, "sysdb_search_user_by_name error [%d][%s].",
ret, strerror(ret));
- talloc_zfree(msg);
On (19/05/14 11:17), Jakub Hrozek wrote:
On Mon, May 19, 2014 at 09:34:58AM +0200, Lukas Slebodnik wrote:
ehlo,
patch is attached.
LS
From 159e5434e4f175bd309b652d6e305d4a3c1c6f06 Mon Sep 17 00:00:00 2001 From: Lukas Slebodnik lslebodn@redhat.com Date: Sat, 17 May 2014 16:18:32 +0200 Subject: [PATCH] TEST: Test an empty results from functions sysdb_search_*
src/tests/sysdb-tests.c | 137 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+)
diff --git a/src/tests/sysdb-tests.c b/src/tests/sysdb-tests.c index 3e4d5f7f0f4e7ba887fab8ccf00d4f89771776f0..4b03f0bd669af522a8b9f44d4bc785e2c28c0492 100644 --- a/src/tests/sysdb-tests.c +++ b/src/tests/sysdb-tests.c @@ -4411,6 +4411,140 @@ START_TEST(test_sysdb_attrs_get_string_array) } END_TEST
+START_TEST (test_sysdb_search_return_ENOENT) +{
- struct sysdb_test_ctx *test_ctx;
- int ret;
- struct ldb_dn *user_dn = NULL;
- struct ldb_message *msg = NULL;
- struct ldb_message **msgs = NULL;
- struct ldb_result *res = NULL;
- size_t count;
- //const char *attrs[] = { SYSDB_NAME, NULL };
You should remove the comment.
Fixed.
LS
On Mon, May 19, 2014 at 12:57:03PM +0200, Lukas Slebodnik wrote:
On (19/05/14 11:17), Jakub Hrozek wrote:
On Mon, May 19, 2014 at 09:34:58AM +0200, Lukas Slebodnik wrote:
ehlo,
patch is attached.
LS
From 159e5434e4f175bd309b652d6e305d4a3c1c6f06 Mon Sep 17 00:00:00 2001 From: Lukas Slebodnik lslebodn@redhat.com Date: Sat, 17 May 2014 16:18:32 +0200 Subject: [PATCH] TEST: Test an empty results from functions sysdb_search_*
src/tests/sysdb-tests.c | 137 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+)
diff --git a/src/tests/sysdb-tests.c b/src/tests/sysdb-tests.c index 3e4d5f7f0f4e7ba887fab8ccf00d4f89771776f0..4b03f0bd669af522a8b9f44d4bc785e2c28c0492 100644 --- a/src/tests/sysdb-tests.c +++ b/src/tests/sysdb-tests.c @@ -4411,6 +4411,140 @@ START_TEST(test_sysdb_attrs_get_string_array) } END_TEST
+START_TEST (test_sysdb_search_return_ENOENT) +{
- struct sysdb_test_ctx *test_ctx;
- int ret;
- struct ldb_dn *user_dn = NULL;
- struct ldb_message *msg = NULL;
- struct ldb_message **msgs = NULL;
- struct ldb_result *res = NULL;
- size_t count;
- //const char *attrs[] = { SYSDB_NAME, NULL };
You should remove the comment.
Fixed.
LS
OK, good to go!
ACK
On Tue, May 27, 2014 at 04:55:45PM +0200, Jakub Hrozek wrote:
On Mon, May 19, 2014 at 12:57:03PM +0200, Lukas Slebodnik wrote:
On (19/05/14 11:17), Jakub Hrozek wrote:
On Mon, May 19, 2014 at 09:34:58AM +0200, Lukas Slebodnik wrote:
ehlo,
patch is attached.
LS
From 159e5434e4f175bd309b652d6e305d4a3c1c6f06 Mon Sep 17 00:00:00 2001 From: Lukas Slebodnik lslebodn@redhat.com Date: Sat, 17 May 2014 16:18:32 +0200 Subject: [PATCH] TEST: Test an empty results from functions sysdb_search_*
src/tests/sysdb-tests.c | 137 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 137 insertions(+)
diff --git a/src/tests/sysdb-tests.c b/src/tests/sysdb-tests.c index 3e4d5f7f0f4e7ba887fab8ccf00d4f89771776f0..4b03f0bd669af522a8b9f44d4bc785e2c28c0492 100644 --- a/src/tests/sysdb-tests.c +++ b/src/tests/sysdb-tests.c @@ -4411,6 +4411,140 @@ START_TEST(test_sysdb_attrs_get_string_array) } END_TEST
+START_TEST (test_sysdb_search_return_ENOENT) +{
- struct sysdb_test_ctx *test_ctx;
- int ret;
- struct ldb_dn *user_dn = NULL;
- struct ldb_message *msg = NULL;
- struct ldb_message **msgs = NULL;
- struct ldb_result *res = NULL;
- size_t count;
- //const char *attrs[] = { SYSDB_NAME, NULL };
You should remove the comment.
Fixed.
LS
OK, good to go!
ACK
master: 4b0c83e022c396e984d862ced5b6219e4ef04429
sssd-devel@lists.fedorahosted.org