selftest: Update getnc_unpriv tests to pass against Samba
authorTim Beale <timbeale@catalyst.net.nz>
Wed, 16 Aug 2017 03:00:31 +0000 (15:00 +1200)
committerAndrew Bartlett <abartlet@samba.org>
Tue, 29 Aug 2017 05:23:28 +0000 (07:23 +0200)
commit37ed946c75e4f62b173b943b0db649fdbdbf72ed
treeedb0d8db598fa4c52b85ea8b63edd8cabffaaff6
parent2d0766a48b3a62de15aa834b1aedd0f6b8c7f6e1
selftest: Update getnc_unpriv tests to pass against Samba

In general Windows seems to return BAD_DN rather than ACCESS_DENIED for
an unprivileged user. In the the long-term, it's unrealistic to think
that Samba and Windows will agree exactly on every error code returned.
So for the tests to be maintainable and pass against Windows and Samba,
they need to handle differences in expected errors. To get around this
problem, I've changed the expected_error to be a set, so that multiple
error codes (one for Microsoft, one for Samba) can be specified for each
test case. This approach also highlights the cases where Microsoft and
Samba currently differ.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Signed-off-by: Tim Beale <timbeale@catalyst.net.nz>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
selftest/knownfail.d/getnc_unpriv [deleted file]
source4/torture/drs/python/getnc_unpriv.py