From 0bfbae0f50df01ff058a23419173fd0553281fab Mon Sep 17 00:00:00 2001
From: Günther Deschner <gd@samba.org>
Date: Fri, 24 Oct 2008 00:05:05 +0200
Subject: netapi: make sure to always cleanup after testing NetUser calls.

Guenther
---
 source3/lib/netapi/tests/netuser.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/source3/lib/netapi/tests/netuser.c b/source3/lib/netapi/tests/netuser.c
index 7bbc5ca347..41f794bf34 100644
--- a/source3/lib/netapi/tests/netuser.c
+++ b/source3/lib/netapi/tests/netuser.c
@@ -449,6 +449,10 @@ NET_API_STATUS netapitest_user(struct libnetapi_ctx *ctx,
 
 	printf("NetUser tests succeeded\n");
  out:
+	/* cleanup */
+	NetUserDel(hostname, username);
+	NetUserDel(hostname, username2);
+
 	if (status != 0) {
 		printf("NetUser testsuite failed with: %s\n",
 			libnetapi_get_error_string(ctx, status));
-- 
cgit