From: Volker Lendecke Date: Fri, 3 May 2024 12:52:42 +0000 (+0200) Subject: tests: Clean up behind ourselves in test_create_reparse X-Git-Tag: tdb-1.4.11~866 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7dc07710fbede128d0b7064f78d86dfabd47cf5d;p=thirdparty%2Fsamba.git tests: Clean up behind ourselves in test_create_reparse Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison --- diff --git a/python/samba/tests/reparsepoints.py b/python/samba/tests/reparsepoints.py index 76bfb6a733a..3da6aedf974 100644 --- a/python/samba/tests/reparsepoints.py +++ b/python/samba/tests/reparsepoints.py @@ -74,9 +74,11 @@ class ReparsePoints(samba.tests.libsmb.LibsmbTests): fd = conn.create( filename, - DesiredAccess=sec.SEC_FILE_WRITE_ATTRIBUTE, + DesiredAccess=sec.SEC_FILE_WRITE_ATTRIBUTE | sec.SEC_STD_DELETE, CreateDisposition=libsmb.FILE_CREATE) + conn.delete_on_close(fd, 1) + with self.assertRaises(NTSTATUSError) as e: conn.fsctl(fd, libsmb.FSCTL_SET_REPARSE_POINT, b'', 0)