summaryrefslogtreecommitdiff
path: root/source4/scripting/python
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2008-04-08 03:29:12 +0200
committerJelmer Vernooij <jelmer@samba.org>2008-04-08 03:29:12 +0200
commit1f474f4a545752f7ac0ad402d01d1e768b973dbe (patch)
treeee403776b858a7b46497c74c069bd0c66ef55904 /source4/scripting/python
parent5cf6c42658755f0a126a5bd6cdd9f215779b75a8 (diff)
downloadsamba-1f474f4a545752f7ac0ad402d01d1e768b973dbe.tar.gz
samba-1f474f4a545752f7ac0ad402d01d1e768b973dbe.tar.bz2
samba-1f474f4a545752f7ac0ad402d01d1e768b973dbe.zip
Add trivial test for unixinfo interface.
(This used to be commit b6b7171f70114bd27ca8db09964c65cacb9cea92)
Diffstat (limited to 'source4/scripting/python')
-rw-r--r--source4/scripting/python/samba/tests/dcerpc/unix.py30
1 files changed, 30 insertions, 0 deletions
diff --git a/source4/scripting/python/samba/tests/dcerpc/unix.py b/source4/scripting/python/samba/tests/dcerpc/unix.py
new file mode 100644
index 0000000000..99c84c08da
--- /dev/null
+++ b/source4/scripting/python/samba/tests/dcerpc/unix.py
@@ -0,0 +1,30 @@
+#!/usr/bin/python
+
+# Unix SMB/CIFS implementation.
+# Copyright (C) Jelmer Vernooij <jelmer@samba.org> 2008
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+
+import unixinfo
+import unittest
+from samba.tests import get_loadparm
+
+class UnixinfoTests(unittest.TestCase):
+ def setUp(self):
+ self.conn = unixinfo.unixinfo("ncalrpc:", get_loadparm())
+
+ def test_getpwuid(self):
+ (count, infos) = self.conn.GetPWUid(1, [0])
+ self.assertEquals(1, len(infos))