diff options
author | Tim Potter <tpot@samba.org> | 2004-10-31 03:54:20 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:05:06 -0500 |
commit | 75f1497c32bbae1d603b80810412a544303fce94 (patch) | |
tree | 92d401c47b9a97a151ac5a817cc6145ad7c97aed /source4/scripting/swig | |
parent | b24fcfc1aadf56130f9f2f2371282c0c399611c2 (diff) | |
download | samba-75f1497c32bbae1d603b80810412a544303fce94.tar.gz samba-75f1497c32bbae1d603b80810412a544303fce94.tar.bz2 samba-75f1497c32bbae1d603b80810412a544303fce94.zip |
r3401: Fix IDL for SetForm RPC.
(This used to be commit 206f3de297c397c8894f9855ea8571c68823e1fc)
Diffstat (limited to 'source4/scripting/swig')
-rw-r--r-- | source4/scripting/swig/torture/spoolss.py | 39 |
1 files changed, 29 insertions, 10 deletions
diff --git a/source4/scripting/swig/torture/spoolss.py b/source4/scripting/swig/torture/spoolss.py index 78c74569f5..4c65669d8f 100644 --- a/source4/scripting/swig/torture/spoolss.py +++ b/source4/scripting/swig/torture/spoolss.py @@ -129,6 +129,26 @@ def test_GetForm(pipe, handle, formname): return result['info']['info1'] +def test_SetForm(pipe, handle, form): + + print 'testing spoolss_SetForm' + + r = {} + r['handle'] = handle + r['level'] = 1 + r['formname'] = form['info1']['formname'] + r['info'] = form + + dcerpc.spoolss_SetForm(pipe, r) + + newform = test_GetForm(pipe, handle, r['formname']) + + if form['info1'] != newform: + print 'SetForm: mismatch: %s != %s' % \ + (r['info']['info1'], f) + sys.exit(1) + + def test_AddForm(pipe, handle): print 'testing spoolss_AddForm' @@ -141,13 +161,13 @@ def test_AddForm(pipe, handle): r['info'] = {} r['info']['info1'] = {} r['info']['info1']['formname'] = formname - r['info']['info1']['flags'] = 0 - r['info']['info1']['width'] = 1 - r['info']['info1']['length'] = 2 - r['info']['info1']['left'] = 3 - r['info']['info1']['top'] = 4 - r['info']['info1']['right'] = 5 - r['info']['info1']['bottom'] = 6 + r['info']['info1']['flags'] = 0x0002 + r['info']['info1']['width'] = 100 + r['info']['info1']['length'] = 100 + r['info']['info1']['left'] = 0 + r['info']['info1']['top'] = 1000 + r['info']['info1']['right'] = 2000 + r['info']['info1']['bottom'] = 3000 try: result = dcerpc.spoolss_AddForm(pipe, r) @@ -159,14 +179,13 @@ def test_AddForm(pipe, handle): f = test_GetForm(pipe, handle, formname) if r['info']['info1'] != f: - print 'Form type mismatch: %s != %s' % \ + print 'AddForm: mismatch: %s != %s' % \ (r['info']['info1'], f) sys.exit(1) r['formname'] = formname - r['info']['info1']['unknown'] = 1 - dcerpc.spoolss_SetForm(pipe, r) + test_SetForm(pipe, handle, r['info']) test_DeleteForm(pipe, handle, formname) |