summaryrefslogtreecommitdiff
path: root/source4/torture/rpc
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2010-03-15 16:11:43 +0100
committerGünther Deschner <gd@samba.org>2010-03-15 17:27:12 +0100
commit08ec9b7e734dcdd46440abba49e980cae01b1e44 (patch)
tree4e9cbe17d1b0e05ff2853b6efd11bbafc0101860 /source4/torture/rpc
parent386f15c62bb4d3517de719c750252e06cf3b1fb1 (diff)
downloadsamba-08ec9b7e734dcdd46440abba49e980cae01b1e44.tar.gz
samba-08ec9b7e734dcdd46440abba49e980cae01b1e44.tar.bz2
samba-08ec9b7e734dcdd46440abba49e980cae01b1e44.zip
s4-smbtorture: fill PrinterDriverData with more values for consistency test.
Guenther
Diffstat (limited to 'source4/torture/rpc')
-rw-r--r--source4/torture/rpc/spoolss.c25
1 files changed, 22 insertions, 3 deletions
diff --git a/source4/torture/rpc/spoolss.c b/source4/torture/rpc/spoolss.c
index e9b4327237..ee937db14a 100644
--- a/source4/torture/rpc/spoolss.c
+++ b/source4/torture/rpc/spoolss.c
@@ -3179,10 +3179,23 @@ static bool test_EnumPrinterData_consistency(struct torture_context *tctx,
torture_assert(tctx,
reg_string_to_val(tctx, lp_iconv_convenience(tctx->lp_ctx),
- "REG_SZ", "torture_data", &type, &blob), "");
+ "REG_SZ", "torture_data1", &type, &blob), "");
torture_assert(tctx,
- test_SetPrinterData(tctx, p, handle, "torture_value", type, blob.data, blob.length),
+ test_SetPrinterData(tctx, p, handle, "torture_value1", type, blob.data, blob.length),
+ "SetPrinterData failed");
+
+ blob = data_blob_string_const("torture_data2");
+
+ torture_assert(tctx,
+ test_SetPrinterData(tctx, p, handle, "torture_value2", REG_BINARY, blob.data, blob.length),
+ "SetPrinterData failed");
+
+ blob = data_blob_talloc(tctx, NULL, 4);
+ SIVAL(blob.data, 0, 0x11223344);
+
+ torture_assert(tctx,
+ test_SetPrinterData(tctx, p, handle, "torture_value3", type, blob.data, blob.length),
"SetPrinterData failed");
torture_assert(tctx,
@@ -3250,7 +3263,13 @@ static bool test_EnumPrinterData_consistency(struct torture_context *tctx,
}
torture_assert(tctx,
- test_DeletePrinterData(tctx, p, handle, "torture_value"),
+ test_DeletePrinterData(tctx, p, handle, "torture_value1"),
+ "DeletePrinterData failed");
+ torture_assert(tctx,
+ test_DeletePrinterData(tctx, p, handle, "torture_value2"),
+ "DeletePrinterData failed");
+ torture_assert(tctx,
+ test_DeletePrinterData(tctx, p, handle, "torture_value3"),
"DeletePrinterData failed");
torture_comment(tctx, "EnumPrinterData vs EnumPrinterDataEx consistency test succeeded\n\n");