summaryrefslogtreecommitdiff
path: root/selftest/tests.py
Commit message (Collapse)AuthorAgeFilesLines
* CVE-2018-1139 libcli/auth: Add initial tests for ntlm_password_check()Andrew Bartlett2018-08-111-0/+2
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=13360 Signed-off-by: Andrew Bartlett <abartlet@samba.org>
* selftest/tests.py: remove always-needed, never-set with_cmocka flagDouglas Bagnall2018-08-111-10/+8
| | | | | | | | | | We have cmocka in third_party, so we are never without it. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> (Backported from commit 33ef0e57a4f08eae5ea06f482374fbc0a1014de6 by Andrew Bartlett)
* selftest: Add more corruption cases for runtime and dbcheckAndrew Bartlett2017-11-291-0/+5
| | | | | | | | | These tests now confirm we can handle these issues at runtime as well as at dbcheck Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> (cherry picked from commit 4815efc0e3f89079e7c9b868b7514ea7c49a807c)
* selftest: test pam_winbind with a local user on ad_memberStefan Metzmacher2017-06-131-1/+5
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* selftest: use "$DC_USERNAME" and "$DC_PASSWORD" for the pam_winbind testStefan Metzmacher2017-06-131-1/+2
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* python/samba/tests: don't use hardcoded names in *pam_winbind* testsStefan Metzmacher2017-06-131-1/+2
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* libcli:smb: Add unit test for smb_bytes_pull_str()Andreas Schneider2017-06-091-0/+3
| | | | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=12824 Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org>
* unittest: Add testsuite for smb_probe_module()Andreas Schneider2017-06-061-0/+2
| | | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=12780 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* unittest: Add testsuite for is_known_pipename()Andreas Schneider2017-06-061-0/+2
| | | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=12780 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* waf: Only build pam_wrapper if we build with pamAndreas Schneider2017-04-121-2/+4
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Uri Simchoni <uri@samba.org>
* python: Add a simple pam_winbind testAndreas Schneider2017-04-071-0/+4
| | | | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Fri Apr 7 14:19:23 CEST 2017 on sn-devel-144
* python: selftests: Enable samba.getopt tests execution with Python 3Lumir Balhar2017-03-101-1/+1
| | | | | | Signed-off-by: Lumir Balhar <lbalhar@redhat.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
* python: samba.tests.core: Port and enable core tests in Python 3Lumir Balhar2017-03-101-1/+1
| | | | | | | | | Port samba core tests to Python 3 compatible form and enable their execution with Python 3. Signed-off-by: Lumir Balhar <lbalhar@redhat.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
* python: samba.auth: Port samba.auth to Python 3 compatible formLumir Balhar2017-03-101-1/+1
| | | | | | | | | Port samba.auth Python module to Python 3 compatible form and enable tests execution with Python 3. Signed-off-by: Lumir Balhar <lbalhar@redhat.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
* python: samba.tests.dcerpc.misc: Port and enable testsLumir Balhar2017-03-101-1/+1
| | | | | | | | | Port tests of samba.dcerpc.misc module to Python 3 compatible form and enable their execution with Python 3. Signed-off-by: Lumir Balhar <lbalhar@redhat.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
* python: samba.tests: Enable Python 3 tests for ported modulesLumir Balhar2017-03-101-2/+3
| | | | | | | | Enable tests with Python 3 for Python 3 compatible modules. Signed-off-by: Lumir Balhar <lbalhar@redhat.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
* script: Add test script for traffic_summary.plGary Lockyer2017-03-011-0/+4
| | | | | | | | | | | | Add the test script for traffic_summary.pl, test data in previous commit. Signed-off-by: Gary Lockyer <gary@catalyst.net.nz> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Douglas Bagnall <dbagnall@samba.org> Autobuild-Date(master): Wed Mar 1 09:01:07 CET 2017 on sn-devel-144
* testsuite: Add cmocka unit test for smb_krb5_kt_open()Andreas Schneider2016-12-161-2/+13
| | | | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Dec 16 05:43:12 CET 2016 on sn-devel-144
* selftest: Add test for link and deleted link behaviour in dbcheckAndrew Bartlett2016-11-221-0/+5
| | | | | | | | | | The other dbcheck tests were getting over-complex, so we start a new test here based on tombestone-expunge.sh, as we are looking at very similar problems Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz> BUG: https://bugzilla.samba.org/show_bug.cgi?id=12297
* Remove unused python selftestDouglas Bagnall2016-09-011-1/+0
| | | | | | | | | | | It doesn't work, isn't changing, and causes a little bit of extra confusion. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Thu Sep 1 13:29:46 CEST 2016 on sn-devel-144
* selftest: Add test for 'samba-tool tombstones expunge'Andrew Bartlett2016-09-011-0/+5
| | | | | Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* selftest: Correct name of samba4.blackbox.dbcheck.release-4-5-0-pre1Andrew Bartlett2016-09-011-5/+5
| | | | | Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* selftest: allow tests.py scripts to run independentlyDouglas Bagnall2016-08-311-0/+1
| | | | | | | | | These generate lists of test commands. Usually they are run in special environments, but they should work from the command line. This restores the intended behaviour. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* dbcheck linked attribute tests: save environment with bad linksDouglas Bagnall2016-07-151-0/+5
| | | | | | | | | We save a database snapshot that contains linked attributes that should have been deleted, and make sure dbcheck fixes those links without ruining anything else. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* tests/dcerpc: add tests for string allocation and deletionDouglas Bagnall2016-05-101-0/+1
| | | | | | | | Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Tue May 10 05:11:42 CEST 2016 on sn-devel-144
* selftest: Enable samba.tests.dcerpc.array testDouglas Bagnall2016-05-101-0/+1
| | | | | Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* CVE-2016-0771: tests: rename test getopt to get_optGarming Sam2016-03-101-1/+1
| | | | | | | | | | | | This avoids any conflicts in this directory with the original toplevel getopt. BUG: https://bugzilla.samba.org/show_bug.cgi?id=11128 BUG: https://bugzilla.samba.org/show_bug.cgi?id=11686 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* selftest: Confirm a demote of a real network worksAndrew Bartlett2015-10-261-0/+4
| | | | | | | | Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Mon Oct 26 08:17:47 CET 2015 on sn-devel-104
* python/tests: Add tests for integer overflow handlingAndrew Bartlett2015-08-241-0/+1
| | | | | | | | | | This also documents an issue with our python bindings and lists, as changes to integers in a list of integers are not preserved BUG: https://bugzilla.samba.org/show_bug.cgi?id=11429 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* KCC: add tests for kcc.graph repltimes functionsDouglas Bagnall2015-06-121-0/+1
| | | | | | | | There used to be bugs in these. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* KCC: add a very puny stub for kcc.kcc_utils testsDouglas Bagnall2015-06-121-0/+1
| | | | | | Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* KCC move and fix ldif_import_export and graph_utils testsDouglas Bagnall2015-06-121-2/+2
| | | | | | Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* KCC: ldif_utils: ldif_to_samdb doesn't need creds; begin selftestDouglas Bagnall2015-05-301-0/+1
| | | | | | | | | | The tests are based on the testdata/ldif-utils-test-multisite.ldif which describes a multisite windows network. It was constructed by Garming Sam. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* KCC: test suite for the graph_utilsDouglas Bagnall2015-05-291-0/+1
| | | | | | | | | | | This found a few bugs in the tests which were fixed. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Fri May 29 13:55:54 CEST 2015 on sn-devel-104
* Move waf into third_party/.Jelmer Vernooij2015-03-261-1/+1
| | | | | Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* selftest: rename env dc to ad_dc_ntvfsMichael Adam2015-03-161-1/+1
| | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* selftest/tests.py: Remove testsuite samba.tests.samdb which does not have ↵Jelmer Vernooij2014-11-301-1/+0
| | | | | | | | any tests. Change-Id: I8edcf73aa4a9b61c6e5c7cfb592a4692d4030a29 Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* Fix subunit test suite name.Jelmer Vernooij2014-11-191-1/+6
| | | | | | | | Only run it when testscenarios is installed, as it depends on that. Change-Id: I1e1284024cf94f909e585a55b8a15e33273f167b Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* selftest: Run samba.tests.messaging in an environment where it has servers ↵Andrew Bartlett2014-10-171-1/+1
| | | | | | | | | | | | to list The previous code would run on empty databases. Andrew Bartlett Change-Id: I8f8e736b9ad475b5b3d10e32834450c76edc5ca2 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* Run duplicate symbol check as just another test, rather than as part of "waf ↵Jelmer Vernooij2014-10-141-0/+1
| | | | | | | | | | | | test". This allows it to be scheduled independently as part of a parallel test run, and reduces the overhead of "waf test". Change-Id: I780fd2c4dd711ed27df73f56de98e7f1ffd53aaf Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Bug: https://bugzilla.samba.org/show_bug.cgi?id=10875
* Fix more pep8 issues in code I touched recently.Jelmer Vernooij2014-10-141-7/+30
| | | | | | Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Change-Id: I35f3204bdf5d00b3280d703427ded2fa2163a6f7
* selftest: Add tests for dbcheck detection and removal of partial objectsAndrew Bartlett2014-05-031-0/+1
| | | | | | | | | | | To avoid listing all the provision snapshots, we use a broader blacklist for waf dist and a whitelist for dbcheck-oldrelease.sh Andrew Bartlett Change-Id: Iab0ff4be0b4287dc128a49302836a6f0f7b39678 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* selftst: add tests based on 4.1.0rc3 to check for zero invocationID in ↵Andrew Bartlett2013-09-231-0/+1
| | | | | | | | | | | replPropertyMetaData Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Mon Sep 23 01:29:10 CEST 2013 on sn-devel-104
* selftest: do not run doc tests if we don't build manpagesMatthieu Patou2013-05-061-1/+15
| | | | | | | | | | | if XSLTPROC_MANPAGES is not set then manpages won't be built so there is no sense trying to test it. Signed-off-by: Matthieu Patou <mat@matws.net> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Mon May 6 12:53:37 CEST 2013 on sn-devel-104
* selftest: Run dbcheck and improved upgrdeprovision tests against release-4-0-0Andrew Bartlett2013-03-041-2/+4
| | | | | | | | | | The improved upgradeprovision tests now call ldapcmp to verify the changes made do actually bring the database in line with a fresh provision. Andrew Bartlett Reviewed-by: Stefan Metzmacher <metze@samba.org>
* selftest: Add test of upgradeprovision using the old alpha13 treeAndrew Bartlett2013-01-271-0/+1
| | | | | | | | | | | This ensures that upgradeprovision works as expected on a known good old database. Andrew Bartlett Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Sun Jan 27 11:55:54 CET 2013 on sn-devel-104
* tests: Convert find_missing_doc into a unit test.Jelmer Vernooij2012-10-191-0/+1
|
* selftest: Move more tests to common list script.Jelmer Vernooij2012-10-121-0/+26
| | | | | Autobuild-User(master): Jelmer Vernooij <jelmer@samba.org> Autobuild-Date(master): Fri Oct 12 02:06:42 CEST 2012 on sn-devel-104
* selftest: Move some tests to common test script.Jelmer Vernooij2012-10-111-0/+2
|
* selftests.tests: Remove reference to Samba 4.Jelmer Vernooij2012-10-111-4/+4
|