tests: Fix use of self.assertRaises()
commitf10f259eaebdb98f5e0827482e98f5abeb65e55c
authorVolker Lendecke <vl@samba.org>
Fri, 2 Dec 2022 08:26:56 +0000 (2 09:26 +0100)
committerVolker Lendecke <vl@samba.org>
Mon, 5 Dec 2022 15:06:32 +0000 (5 15:06 +0000)
tree039998d7ebbea1f0709e337a11f704ee35c163d4
parent73233bc341e0dfe6cb61a638707567e79e639b28
tests: Fix use of self.assertRaises()

The with statement creates a new variable. I thought it opens a block
where "e" is only valid in that block. But instead it runs the whole
thing, expecting an exception somewhere. Learning python....

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: David Mulder <dmulder@samba.org>
python/samba/tests/reparsepoints.py
python/samba/tests/smb2symlink.py